]> granicus.if.org Git - imagemagick/commitdiff
Exit early when identifying the image.
authorDirk Lemstra <dirk@git.imagemagick.org>
Thu, 20 Jul 2017 20:26:48 +0000 (22:26 +0200)
committerDirk Lemstra <dirk@git.imagemagick.org>
Thu, 20 Jul 2017 20:26:48 +0000 (22:26 +0200)
coders/dng.c

index e9f0ef3aa375967e2f0248e88fbb79e4d18d7eff..1e1267817edbcd2422fd7127d454af51713c56ee 100644 (file)
@@ -258,6 +258,12 @@ static Image *ReadDNGImage(const ImageInfo *image_info,ExceptionInfo *exception)
         libraw_close(raw_info);
         return(DestroyImageList(image));
       }
+    if (image_info->ping != MagickFalse)
+      {
+        libraw_dcraw_clear_mem(raw_image);
+        libraw_close(raw_info);
+        return(image);
+      }
     p=(unsigned short *) raw_image->data;
     for (y=0; y < (ssize_t) image->rows; y++)
     {