From f61f674e36afd06c96bcb77134ded8ce54774cc5 Mon Sep 17 00:00:00 2001 From: Cristy Date: Sun, 13 May 2018 19:15:05 -0400 Subject: [PATCH] ... --- coders/mat.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/coders/mat.c b/coders/mat.c index 3af3c7e0e..b11c065db 100644 --- a/coders/mat.c +++ b/coders/mat.c @@ -984,9 +984,13 @@ MATLAB_KO: } #endif - if (MATLAB_HDR.DataType!=miMATRIX) + if (MATLAB_HDR.DataType != miMATRIX) { clone_info=DestroyImageInfo(clone_info); +#if defined(MAGICKCORE_ZLIB_DELEGATE) + if (image2 != image) + DeleteImageFromList(&image2); +#endif continue; /* skip another objects. */ } @@ -1074,7 +1078,7 @@ MATLAB_KO: MATLAB_HDR.StructureClass != mxINT64_CLASS && MATLAB_HDR.StructureClass != mxUINT64_CLASS) /* uint64 + uint64 3D */ { - if ((image2 != (Image*) NULL) && (image2 != (Image *) image)) + if (image2 != (Image*) NULL) { CloseBlob(image2); DeleteImageFromList(&image2); -- 2.40.0