]> granicus.if.org Git - imagemagick/commitdiff
...
authorCristy <urban-warrior@imagemagick.org>
Tue, 12 Jun 2018 00:26:21 +0000 (20:26 -0400)
committerCristy <urban-warrior@imagemagick.org>
Tue, 12 Jun 2018 00:26:21 +0000 (20:26 -0400)
coders/png.c

index 33723484a3ffbe0dcf14679c190485a33fa80796..8b84a83ef001adaf883488517f68d6668062065e 100644 (file)
@@ -6127,7 +6127,7 @@ static Image *ReadOneMNGImage(MngInfo* mng_info, const ImageInfo *image_info,
           {
             /* Read DISC or SEEK.  */
 
-            if ((length == 0) || !memcmp(type,mng_SEEK,4))
+            if ((length == 0) || (length % 2) || !memcmp(type,mng_SEEK,4))
               {
                 for (i=1; i < MNG_MAX_OBJECTS; i++)
                   MngInfoDiscardObject(mng_info,i);