[master] Removed some newly-added TAB characters from pngpread.c

and pngrtran.c, and fixed some indentation in pngpread.c and pngrutil.c
This commit is contained in:
Glenn Randers-Pehrson 2010-06-30 23:07:02 -05:00
parent 2302a4d04f
commit d6a0cbaade
5 changed files with 49 additions and 81 deletions

View File

@ -1,5 +1,5 @@
Libpng 1.4.4beta01 - June 27, 2010
Libpng 1.4.4beta01 - July 1, 2010
This is not intended to be a public release. It will be replaced
within a few weeks by a public version or by another test version.
@ -24,47 +24,13 @@ Other information:
1.4.4beta01-README.txt
1.4.4beta01-LICENSE.txt
Changes since the last public release (1.4.2):
Changes since the last public release (1.4.3):
version 1.4.3beta01 [June 18, 2010]
Added missing quotation marks in the aix block of configure.ac
The new "vstudio" project was missing from the zip and 7z distributions.
In pngpread.c: png_push_have_row() add check for new_row > height
version 1.4.3beta02 [June 18, 2010]
Removed the now-redundant check for out-of-bounds new_row from example.c
version 1.4.3beta03 [June 18, 2010]
In pngpread.c: png_push_finish_row() add check for too many rows.
version 1.4.3beta04 [June 19, 2010]
In pngpread.c: png_push_process_row() add check for too many rows.
Removed the checks added in beta01 and beta03, as they are now redundant.
version 1.4.3beta05 [June 20, 2010]
Rewrote png_process_IDAT_data to consistently treat extra data as warnings
and handle end conditions more cleanly.
Removed the new (beta04) check in png_push_process_row().
version 1.4.3rc01 [June 21, 2010]
Revised some comments in png_process_IDAT_data().
version 1.4.3rc03 [June 22, 2010]
Revised pngpread.c patch of beta05 to avoid an endless loop.
Changed char *msg to PNG_CONST char *msg in pngrutil.c
Stop memory leak when reading a malformed sCAL chunk.
Removed some trailing blanks.
version 1.4.3rc03 [June 23, 2010]
Revised pngpread.c patch of beta05 to avoid an endless loop.
version 1.4.3 [June 26, 2010]
Updated some of the "last changed" dates.
version 1.4.4beta01 [June 27, 2010]
version 1.4.4beta01 [July 1, 2010]
Removed extraneous new_push_process_row.c file.
Revised the "SEE ALSO" style of libpng.3, libpngpf.3, and png.5
Removed some newly-added TAB characters from pngpread.c.
Fixed some indentation in pngpread.c and pngrutil.c
Send comments/corrections/commendations to glennrp at users.sourceforge.net
or to png-mng-implement at lists.sf.net (subscription required; visit

View File

@ -2610,9 +2610,11 @@ version 1.4.3rc03 [June 23, 2010]
version 1.4.3 [June 26, 2010]
Updated some of the "last changed" dates.
version 1.4.4beta01 [June 27, 2010]
version 1.4.4beta01 [July 1, 2010]
Removed extraneous new_push_process_row.c file.
Revised the "SEE ALSO" style of libpng.3, libpngpf.3, and png.5
Removed some newly-added TAB characters from pngpread.c.
Fixed some indentation in pngpread.c and pngrutil.c
Send comments/corrections/commendations to glennrp at users.sourceforge.net
or to png-mng-implement at lists.sf.net (subscription required; visit

View File

@ -843,7 +843,7 @@ png_process_IDAT_data(png_structp png_ptr, png_bytep buffer,
* or the stream marked as finished.
*/
while (png_ptr->zstream.avail_in > 0 &&
!(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED))
!(png_ptr->flags & PNG_FLAG_ZLIB_FINISHED))
{
int ret;
@ -872,49 +872,49 @@ png_process_IDAT_data(png_structp png_ptr, png_bytep buffer,
/* Check for any failure before proceeding. */
if (ret != Z_OK && ret != Z_STREAM_END)
{
/* Terminate the decompression. */
png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
/* Terminate the decompression. */
png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
/* This may be a truncated stream (missing or
* damaged end code). Treat that as a warning.
*/
* damaged end code). Treat that as a warning.
*/
if (png_ptr->row_number >= png_ptr->num_rows ||
png_ptr->pass > 6)
png_warning(png_ptr, "Truncated compressed data in IDAT");
else
png_error(png_ptr, "Decompression error in IDAT");
png_ptr->pass > 6)
png_warning(png_ptr, "Truncated compressed data in IDAT");
else
png_error(png_ptr, "Decompression error in IDAT");
/* Skip the check on unprocessed input */
/* Skip the check on unprocessed input */
return;
}
/* Did inflate output any data? */
if (png_ptr->zstream.next_out != png_ptr->row_buf)
{
/* Is this unexpected data after the last row?
* If it is, artificially terminate the LZ output
* here.
*/
/* Is this unexpected data after the last row?
* If it is, artificially terminate the LZ output
* here.
*/
if (png_ptr->row_number >= png_ptr->num_rows ||
png_ptr->pass > 6)
png_ptr->pass > 6)
{
/* Extra data. */
png_warning(png_ptr, "Extra compressed data in IDAT");
/* Extra data. */
png_warning(png_ptr, "Extra compressed data in IDAT");
png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
/* Do no more processing; skip the unprocessed
* input check below.
*/
/* Do no more processing; skip the unprocessed
* input check below.
*/
return;
}
}
/* Do we have a complete row? */
if (png_ptr->zstream.avail_out == 0)
png_push_process_row(png_ptr);
/* Do we have a complete row? */
if (png_ptr->zstream.avail_out == 0)
png_push_process_row(png_ptr);
}
/* And check for the end of the stream. */
if (ret == Z_STREAM_END)
png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
png_ptr->flags |= PNG_FLAG_ZLIB_FINISHED;
}
/* All the data should have been processed, if anything
@ -988,7 +988,7 @@ png_push_process_row(png_structp png_ptr)
if (png_ptr->pass == 6 && png_ptr->height <= 4)
{
png_push_have_row(png_ptr, NULL);
png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@ -1028,7 +1028,7 @@ png_push_process_row(png_structp png_ptr)
for (i = 0; i < 4 && png_ptr->pass == 2; i++)
{
png_push_have_row(png_ptr, NULL);
png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@ -1078,13 +1078,13 @@ png_push_process_row(png_structp png_ptr)
for (i = 0; i < 2 && png_ptr->pass == 4; i++)
{
png_push_have_row(png_ptr, NULL);
png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
if (png_ptr->pass == 6) /* Pass 5 might be empty */
{
png_push_have_row(png_ptr, NULL);
png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@ -1103,7 +1103,7 @@ png_push_process_row(png_structp png_ptr)
if (png_ptr->pass == 6) /* Skip top generated row */
{
png_push_have_row(png_ptr, NULL);
png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
@ -1117,7 +1117,7 @@ png_push_process_row(png_structp png_ptr)
if (png_ptr->pass != 6)
break;
png_push_have_row(png_ptr, NULL);
png_push_have_row(png_ptr, NULL);
png_read_push_finish_row(png_ptr);
}
}

View File

@ -1128,20 +1128,20 @@ png_handle_iCCP(png_structp png_ptr, png_infop info_ptr, png_uint_32 length)
if (profile_size > profile_length)
{
#ifdef PNG_STDIO_SUPPORTED
char umsg[50];
#endif
png_free(png_ptr, png_ptr->chunkdata);
png_ptr->chunkdata = NULL;
png_warning(png_ptr, "Ignoring truncated iCCP profile");
#ifdef PNG_STDIO_SUPPORTED
{
char umsg[50];
png_snprintf(umsg, 50, "declared profile size = %lu",
(unsigned long)profile_size);
png_warning(png_ptr, umsg);
png_snprintf(umsg, 50, "actual profile length = %lu",
(unsigned long)profile_length);
png_warning(png_ptr, umsg);
}
png_snprintf(umsg, 50, "declared profile size = %lu",
(unsigned long)profile_size);
png_warning(png_ptr, umsg);
png_snprintf(umsg, 50, "actual profile length = %lu",
(unsigned long)profile_length);
png_warning(png_ptr, umsg);
#endif
return;
}

View File

@ -673,5 +673,5 @@ png_get_user_transform_ptr(png_structp png_ptr)
#endif
}
#endif /* PNG_READ_USER_TRANSFORM_SUPPORTED ||
PNG_WRITE_USER_TRANSFORM_SUPPORTED */
PNG_WRITE_USER_TRANSFORM_SUPPORTED */
#endif /* PNG_READ_SUPPORTED || PNG_WRITE_SUPPORTED */