]> granicus.if.org Git - imagemagick/commitdiff
https://github.com/ImageMagick/ImageMagick/issues/1515
authorCristy <mikayla-grace@urban-warrior.org>
Sat, 23 Mar 2019 20:18:39 +0000 (16:18 -0400)
committerCristy <mikayla-grace@urban-warrior.org>
Sat, 23 Mar 2019 20:18:39 +0000 (16:18 -0400)
coders/pango.c
coders/vid.c

index fd9040bc4f5462fcda026dafa553f99f4a60964c..5f9118738f2b90964d4debad493fd2c98704bc6d 100644 (file)
@@ -201,8 +201,11 @@ static Image *ReadPANGOImage(const ImageInfo *image_info,
     else
       property=InterpretImageProperties((ImageInfo *) image_info,image,option,
         exception);
-  (void) SetImageProperty(image,"caption",property,exception);
-  property=DestroyString(property);
+  if (property != (char *) NULL)
+    {
+      (void) SetImageProperty(image,"caption",property,exception);
+      property=DestroyString(property);
+    }
   caption=ConstantString(GetImageProperty(image,"caption",exception));
   /*
     Get context.
index 5aa4b0941b13fdc889d868f7f0c3dba0ae687848..dd57930a3ffd991b37fc5422dd40b622a1881401 100644 (file)
@@ -176,8 +176,11 @@ static Image *ReadVIDImage(const ImageInfo *image_info,ExceptionInfo *exception)
       break;
     label=InterpretImageProperties((ImageInfo *) image_info,next_image,
       DefaultTileLabel,exception);
-    (void) SetImageProperty(next_image,"label",label,exception);
-    label=DestroyString(label);
+    if (label != (char *) NULL)
+      {
+        (void) SetImageProperty(next_image,"label",label,exception);
+        label=DestroyString(label);
+      }
     if (image_info->debug != MagickFalse)
       (void) LogMagickEvent(CoderEvent,GetMagickModule(),
         "geometry: %.20gx%.20g",(double) next_image->columns,(double)