From ff9bf44894d1c6126c4d3bafc84d0936cf6af60c Mon Sep 17 00:00:00 2001 From: Cristy Date: Wed, 6 Jul 2016 08:51:47 -0400 Subject: [PATCH] ... --- coders/pdb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/coders/pdb.c b/coders/pdb.c index 65b4c4209..ed9e3d93b 100644 --- a/coders/pdb.c +++ b/coders/pdb.c @@ -401,9 +401,6 @@ static Image *ReadPDBImage(const ImageInfo *image_info,ExceptionInfo *exception) image->columns=(size_t) pdb_image.width; image->rows=(size_t) pdb_image.height; image->depth=8; - status=SetImageExtent(image,image->columns,image->rows,exception); - if (status == MagickFalse) - return(DestroyImageList(image)); image->storage_class=PseudoClass; bits_per_pixel=pdb_image.type == 0 ? 2UL : pdb_image.type == 2 ? 4UL : 1UL; one=1; @@ -414,6 +411,9 @@ static Image *ReadPDBImage(const ImageInfo *image_info,ExceptionInfo *exception) (void) CloseBlob(image); return(GetFirstImageInList(image)); } + status=SetImageExtent(image,image->columns,image->rows,exception); + if (status == MagickFalse) + return(DestroyImageList(image)); packets=(bits_per_pixel*image->columns+7)/8; pixels=(unsigned char *) AcquireQuantumMemory(packets+257UL,image->rows* sizeof(*pixels)); -- 2.40.0