From: cristy Date: Fri, 28 Mar 2014 10:33:33 +0000 (+0000) Subject: (no commit message) X-Git-Tag: 7.0.1-0~2541 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b02ab65cb4669d2a16f66ac5cedafc2215e00aeb;p=imagemagick --- diff --git a/MagickCore/resource.c b/MagickCore/resource.c index c61db77c3..ff8bf6fa3 100644 --- a/MagickCore/resource.c +++ b/MagickCore/resource.c @@ -357,7 +357,6 @@ MagickExport MagickBooleanType GetPathTemplate(char *path) { char *directory, - *p, *value; ExceptionInfo @@ -420,13 +419,18 @@ MagickExport MagickBooleanType GetPathTemplate(char *path) (double) getpid()); directory=DestroyString(directory); #if defined(MAGICKCORE_WINDOWS_SUPPORT) - /* - Ghostscript does not like backslashes so we need to replace them. The - forward slash also works under Windows. - */ - for (p=(path[1] == *DirectorySeparator ? path+2 : path); *p != '\0'; p++) - if (*p == *DirectorySeparator) - *p='/'; + { + register char + *p; + + /* + Ghostscript does not like backslashes so we need to replace them. The + forward slash also works under Windows. + */ + for (p=(path[1] == *DirectorySeparator ? path+2 : path); *p != '\0'; p++) + if (*p == *DirectorySeparator) + *p='/'; + } #endif return(MagickTrue); }