]> granicus.if.org Git - imagemagick/blobdiff - magick/memory.c
(no commit message)
[imagemagick] / magick / memory.c
index 772e3abc527e425e12db68c41d3a1295d887c1c0..9b5d1af53c810e54821e155a1a43324175fa44e8 100644 (file)
@@ -17,7 +17,7 @@
 %                                 July 1998                                   %
 %                                                                             %
 %                                                                             %
-%  Copyright 1999-2010 ImageMagick Studio LLC, a non-profit organization      %
+%  Copyright 1999-2011 ImageMagick Studio LLC, a non-profit organization      %
 %  dedicated to making software imaging solutions freely available.           %
 %                                                                             %
 %  You may not use this file except in compliance with the License.  You may  %
@@ -141,7 +141,7 @@ static MagickMemoryMethods
   {
     (AcquireMemoryHandler) malloc,
     (ResizeMemoryHandler) realloc,
-    (DestroyMemoryHandler)free
+    (DestroyMemoryHandler) free
   };
 
 #if defined(MAGICKCORE_EMBEDDABLE_SUPPORT)
@@ -214,7 +214,7 @@ MagickExport void *AcquireAlignedMemory(const size_t count,const size_t quantum)
       return(memory);
   }
 #endif
-  return(malloc(size));
+  return(malloc(MagickMax(size,AlignedSize)));
 }
 \f
 #if defined(MAGICKCORE_EMBEDDABLE_SUPPORT)