mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
Set png_ptr->old_prev_row_size=0 in pngpread.c and pngrutil.c
This forces the prev_row array to be cleared before the first row of each image and interlace pass.
This commit is contained in:
@@ -2992,11 +2992,12 @@ png_read_finish_row(png_structp png_ptr)
|
||||
if (png_ptr->row_number < png_ptr->num_rows)
|
||||
return;
|
||||
|
||||
png_ptr->old_prev_row_size = 0; /* Force prev_row to be cleared */
|
||||
|
||||
#ifdef PNG_READ_INTERLACING_SUPPORTED
|
||||
if (png_ptr->interlaced)
|
||||
{
|
||||
png_ptr->row_number = 0;
|
||||
png_memset(png_ptr->prev_row, 0, png_ptr->rowbytes + 1);
|
||||
do
|
||||
{
|
||||
png_ptr->pass++;
|
||||
|
||||
Reference in New Issue
Block a user