From a971941b7cab4b90f32be256975cb03a7dbdf7ee Mon Sep 17 00:00:00 2001 From: Dirk Lemstra Date: Sun, 8 Apr 2018 14:25:06 +0200 Subject: [PATCH] Added call to ResetImagePixels because we allow decoding part of the image. --- coders/tiff.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/coders/tiff.c b/coders/tiff.c index 0c0caca21..2afc1cad9 100644 --- a/coders/tiff.c +++ b/coders/tiff.c @@ -1651,6 +1651,12 @@ RestoreMSCWarning goto next_tiff_frame; } status=SetImageExtent(image,image->columns,image->rows,exception); + if (status == MagickFalse) + { + TIFFClose(tiff); + return(DestroyImageList(image)); + } + status=ResetImagePixels(image,exception); if (status == MagickFalse) { TIFFClose(tiff); -- 2.40.0