From e820a26b5dd5908a8126c67212c3ceff983a52ea Mon Sep 17 00:00:00 2001 From: Dirk Lemstra Date: Sun, 11 Mar 2018 08:58:48 +0100 Subject: [PATCH] The image should be destroyed to avoid a memory leak. --- coders/wpg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/coders/wpg.c b/coders/wpg.c index 54fa63315..d179f7e49 100644 --- a/coders/wpg.c +++ b/coders/wpg.c @@ -864,7 +864,7 @@ static Image *ExtractPostscript(Image *image,const ImageInfo *image_info, FINISH: DestroyImageInfo(clone_info); if (status == MagickFalse) - return((Image *) NULL); + return(DestroyImageList(image)); return(image); } -- 2.40.0