fix large animated web support
we were not checking image bounds correctly for very large animated webp images thanks pomirleanu see https://github.com/libvips/libvips/issues/1730
This commit is contained in:
parent
cba371a9ba
commit
d93d9bb43b
@ -506,10 +506,12 @@ read_header( Read *read, VipsImage *out )
|
||||
read->frame_count = 1;
|
||||
}
|
||||
|
||||
/* height can be huge if this is an animated webp image.
|
||||
*/
|
||||
if( read->width <= 0 ||
|
||||
read->height <= 0 ||
|
||||
read->width > 0x3FFF ||
|
||||
read->height > 0x3FFF ) {
|
||||
read->height > VIPS_MAX_COORD ) {
|
||||
vips_error( "webp", "%s", _( "bad image dimensions" ) );
|
||||
return( -1 );
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user