From: Glenn Randers-Pehrson Date: Sun, 30 Jul 2017 08:38:59 +0000 (-0400) Subject: Fix improper use of NULL in the JNG decoder (Issue 632) X-Git-Tag: 7.0.6-5~20 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=1828667e81e53345cfb3eb46539d78757f1aa680;p=imagemagick Fix improper use of NULL in the JNG decoder (Issue 632) --- diff --git a/ChangeLog b/ChangeLog index b4d1adcb7..23bf6513d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,12 +3,14 @@ it was setting image->gamma, but only setting image->colorspace for grayscale and gray-alpha images. Reference https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=32418). + * Fix improper use of NULL in the JNG decoder (Reference + https://github.com/ImageMagick/ImageMagick/issues/632). 2017-07-29 7.0.6-5 Cristy * Off by one error for gradient coder (reference - https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=32416). - + https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=32416), https://github.com/ImageMagick/ImageMagick/issues/612). + 2017-07-28 7.0.6-4 Cristy * Release ImageMagick version 7.0.6-4, GIT revision 20657:4e81160d6:20170728. diff --git a/coders/png.c b/coders/png.c index 9c03e6754..e8e264f0e 100644 --- a/coders/png.c +++ b/coders/png.c @@ -4502,7 +4502,8 @@ static Image *ReadOneJNGImage(MngInfo *mng_info, { if (length > GetBlobSize(image)) { - DestroyJNG(NULL,&color_image,&color_image_info,NULL,NULL); + DestroyJNG(NULL,&color_image,&color_image_info, + &alpha_image,&alpha_image_info); ThrowReaderException(CorruptImageError, "InsufficientImageDataInFile"); }