Skip to content
Permalink
Browse files Browse the repository at this point in the history
Added check for incorrect number of meta channels report in #492.
  • Loading branch information
dlemstra committed May 15, 2017
1 parent 4e6ac0e commit 7fd4194
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions coders/mpc.c
Expand Up @@ -568,6 +568,9 @@ static Image *ReadMPCImage(const ImageInfo *image_info,ExceptionInfo *exception)
if (LocaleCompare(keyword,"number-meta-channels") == 0)
{
image->number_meta_channels=StringToUnsignedLong(options);
if (image->number_meta_channels > MaxPixelChannels)
ThrowReaderException(CorruptImageError,
"ImproperImageHeader");
break;
}
break;
Expand Down

0 comments on commit 7fd4194

Please sign in to comment.