]> granicus.if.org Git - imagemagick/commitdiff
(no commit message)
authorcristy <urban-warrior@git.imagemagick.org>
Wed, 5 Mar 2014 22:52:17 +0000 (22:52 +0000)
committercristy <urban-warrior@git.imagemagick.org>
Wed, 5 Mar 2014 22:52:17 +0000 (22:52 +0000)
MagickCore/opencl.c

index 2cc056b6bf7fe12115a0974663bfd4bf33896830..000f44cdfac0cd57d7680a3aae831171b5c763b6 100644 (file)
@@ -2566,8 +2566,18 @@ const char* GetOpenCLCachedFilesDirectory() {
       if (home != (char *) NULL)
       {
         /*
-        Search $HOME/.config/ImageMagick.
+          Search $HOME/.config/ImageMagick.
         */
+        (void) FormatLocaleString(path,MaxTextExtent,"%s%s.config",home,
+          DirectorySeparator);
+        status=GetPathAttributes(path,&attributes);
+        if (status == MagickFalse) {
+#ifdef MAGICKCORE_WINDOWS_SUPPORT
+          mkdir(path);
+#else
+          mkdir(path, 0777);
+#endif
+        }
         (void) FormatLocaleString(path,MaxTextExtent,"%s%s.config%sImageMagick",
           home,DirectorySeparator,DirectorySeparator);
         home=DestroyString(home);