From 89f10ff11480381946eab8e65616e1a96be29630 Mon Sep 17 00:00:00 2001 From: Cristy Date: Mon, 19 Mar 2018 20:20:11 -0400 Subject: [PATCH] Unit tests pass again --- coders/pcx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/coders/pcx.c b/coders/pcx.c index e56afd134..880565874 100644 --- a/coders/pcx.c +++ b/coders/pcx.c @@ -405,7 +405,7 @@ static Image *ReadPCXImage(const ImageInfo *image_info,ExceptionInfo *exception) if ((size_t) (pcx_info.bits_per_pixel*pcx_info.planes*image->columns) > (pcx_packets*8U)) ThrowPCXException(CorruptImageError,"ImproperImageHeader"); - if ((MagickSizeType) pcx_packets > GetBlobSize(image)) + if ((MagickSizeType) (pcx_packets/8) > GetBlobSize(image)) ThrowPCXException(CorruptImageError,"ImproperImageHeader"); scanline=(unsigned char *) AcquireQuantumMemory(MagickMax(image->columns, pcx_info.bytes_per_line),MagickMax(8,pcx_info.planes)*sizeof(*scanline)); -- 2.40.0