File ImageMagick-CVE-2019-13295,13297.patch of Package ImageMagick.30356

Index: ImageMagick-7.0.7-34/MagickCore/threshold.c
===================================================================
--- ImageMagick-7.0.7-34.orig/MagickCore/threshold.c	2018-05-20 17:55:43.000000000 +0200
+++ ImageMagick-7.0.7-34/MagickCore/threshold.c	2019-07-22 13:58:53.388796197 +0200
@@ -213,6 +213,8 @@ MagickExport Image *AdaptiveThresholdIma
     exception);
   if (threshold_image == (Image *) NULL)
     return((Image *) NULL);
+  if ((width == 0) || (height == 0))
+    return(threshold_image);
   status=SetImageStorageClass(threshold_image,DirectClass,exception);
   if (status == MagickFalse)
     {
openSUSE Build Service is sponsored by