From e111865b3a203af83334ee09ed014355530ab1b5 Mon Sep 17 00:00:00 2001 From: Cristy Date: Thu, 31 May 2018 10:40:41 -0400 Subject: [PATCH] ... --- coders/png.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/coders/png.c b/coders/png.c index 96b9c65f0..cc9693fa4 100644 --- a/coders/png.c +++ b/coders/png.c @@ -4795,7 +4795,8 @@ static Image *ReadOneJNGImage(MngInfo *mng_info, { /* Copy chunk data to alpha_image->blob */ - if (alpha_image != NULL && image_info->ping == MagickFalse) + if ((alpha_image != NULL) && (image_info->ping == MagickFalse) && + (length != 0)) { if (logging != MagickFalse) (void) LogMagickEvent(CoderEvent,GetMagickModule(), -- 2.40.0