]> granicus.if.org Git - imagemagick/commitdiff
Revert method signature change to fix issue #188.
authordirk <dirk@git.imagemagick.org>
Fri, 17 Jun 2016 18:40:27 +0000 (20:40 +0200)
committerdirk <dirk@git.imagemagick.org>
Fri, 17 Jun 2016 18:40:27 +0000 (20:40 +0200)
MagickCore/utility.c
MagickCore/utility.h

index 5d47c5e1ee9225dce807b34eaba0a097c8469652..47b4578f111c96011bbe28c105d4a29d8a4788a4 100644 (file)
@@ -1148,7 +1148,7 @@ MagickPrivate ssize_t GetMagickPageSize(void)
 %
 */
 MagickExport MagickBooleanType GetPathAttributes(const char *path,
-  struct stat *attributes)
+  void *attributes)
 {
   MagickBooleanType
     status;
@@ -1158,8 +1158,9 @@ MagickExport MagickBooleanType GetPathAttributes(const char *path,
       errno=EINVAL;
       return(MagickFalse);
     }
-  (void) ResetMagickMemory(attributes,0,sizeof(*attributes));
-  status=stat_utf8(path,attributes) == 0 ? MagickTrue : MagickFalse;
+  (void) ResetMagickMemory(attributes,0,sizeof(struct stat));
+  status=stat_utf8(path,(struct stat *) attributes) == 0 ? MagickTrue :
+    MagickFalse;
   return(status);
 }
 \f
index b51c1c5f1be8df79566c1a4e90aece64e1f2834c..4c286a86099040cd961e18fc2d89093d99b84f61 100644 (file)
 extern "C" {
 #endif
 
-#if defined(MAGICKCORE_WINDOWS_SUPPORT) || defined(MAGICKCORE_POSIX_SUPPORT)
-# include <sys/stat.h>
-#endif
-
 typedef enum
 {
   UndefinedPath,
@@ -46,7 +42,7 @@ extern MagickExport MagickBooleanType
   AcquireUniqueFilename(char *),
   AcquireUniqueSymbolicLink(const char *,char *),
   ExpandFilenames(int *,char ***),
-  GetPathAttributes(const char *,struct stat *),
+  GetPathAttributes(const char *,void *),
   IsPathAccessible(const char *);
 
 extern MagickExport size_t