mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[libpng16] Another whack at png_handle_sPLT() pointer calculation.
This commit is contained in:
parent
4db6127658
commit
1ceedd0bf6
@ -1670,7 +1670,7 @@ png_handle_sPLT(png_structrp png_ptr, png_inforp info_ptr, png_uint_32 length)
|
|||||||
++entry_start;
|
++entry_start;
|
||||||
|
|
||||||
/* A sample depth should follow the separator, and we should be on it */
|
/* A sample depth should follow the separator, and we should be on it */
|
||||||
if (length < 2 || entry_start - buffer > length - 2)
|
if (length < 2 || entry_start > buffer + (length - 2U))
|
||||||
{
|
{
|
||||||
png_warning(png_ptr, "malformed sPLT chunk");
|
png_warning(png_ptr, "malformed sPLT chunk");
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user