File ImageMagick-CVE-2019-16710.patch of Package ImageMagick.16887

iff --git a/coders/dot.c b/coders/dot.c
index 4ece49434d..a9410aa9fc 100644
--- a/coders/dot.c
+++ b/coders/dot.c
@@ -129,7 +129,10 @@ static Image *ReadDOTImage(const ImageInfo *image_info,ExceptionInfo *exception)
   image=AcquireImage(image_info,exception);
   status=OpenBlob(image_info,image,ReadBinaryBlobMode,exception);
   if (status == MagickFalse)
-    return((Image *) NULL);
+    {
+      image=DestroyImageList(image);
+      return((Image *) NULL);
+    }
   read_info=CloneImageInfo(image_info);
   SetImageInfoBlob(read_info,(void *) NULL,0);
   (void) CopyMagickString(read_info->magick,"SVG",MagickPathExtent);
openSUSE Build Service is sponsored by