Skip to content

Commit

Permalink
improve decompression errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Cristy committed Feb 5, 2023
1 parent 465cec6 commit 1024e92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion coders/wpg.c
Original file line number Diff line number Diff line change
Expand Up @@ -705,7 +705,7 @@ static int UnpackWPG2Raster(Image *image,int bpp)
break;
}
BImgBuff=(unsigned char *) RelinquishMagickMemory(BImgBuff);
return(0);
return(y < (ssize_t) image->rows ? -5 : 0);
}


Expand Down

0 comments on commit 1024e92

Please sign in to comment.