[libpng16] Fix some indentation.

This commit is contained in:
Glenn Randers-Pehrson 2015-06-11 22:00:14 -05:00
parent c6f629ffdd
commit f86720c6c0
5 changed files with 327 additions and 322 deletions

4
png.c
View File

@ -766,13 +766,13 @@ png_get_copyright(png_const_structrp png_ptr)
#else
# ifdef __STDC__
return PNG_STRING_NEWLINE \
"libpng version 1.6.18beta08 - June 6, 2015" PNG_STRING_NEWLINE \
"libpng version 1.6.18beta08 - June 11, 2015" PNG_STRING_NEWLINE \
"Copyright (c) 1998-2015 Glenn Randers-Pehrson" PNG_STRING_NEWLINE \
"Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \
"Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc." \
PNG_STRING_NEWLINE;
# else
return "libpng version 1.6.18beta08 - June 6, 2015\
return "libpng version 1.6.18beta08 - June 11, 2015\
Copyright (c) 1998-2015 Glenn Randers-Pehrson\
Copyright (c) 1996-1997 Andreas Dilger\
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.";

View File

@ -606,6 +606,7 @@ png_push_read_IDAT(png_structrp png_ptr)
png_ptr->current_buffer_size -= save_size;
png_ptr->current_buffer_ptr += save_size;
}
if (png_ptr->idat_size == 0)
{
PNG_PUSH_SAVE_BUFFER_IF_LT(4)

View File

@ -1146,11 +1146,13 @@ png_handle_sBIT(png_structrp png_ptr, png_inforp info_ptr, png_uint_32 length)
return;
for (i=0; i<truelen; ++i)
{
if (buf[i] == 0 || buf[i] > sample_depth)
{
png_chunk_benign_error(png_ptr, "invalid");
return;
}
}
if ((png_ptr->color_type & PNG_COLOR_MASK_COLOR) != 0)
{

View File

@ -97,7 +97,8 @@ png_write_info_before_PLTE(png_structrp png_ptr, png_const_inforp info_ptr)
if ((png_ptr->mode & PNG_HAVE_PNG_SIGNATURE) != 0 && \
png_ptr->mng_features_permitted != 0)
{
png_warning(png_ptr, "MNG features are not allowed in a PNG datastream");
png_warning(png_ptr,
"MNG features are not allowed in a PNG datastream");
png_ptr->mng_features_permitted = 0;
}
#endif
@ -117,15 +118,15 @@ png_write_info_before_PLTE(png_structrp png_ptr, png_const_inforp info_ptr)
* flag set, and if it does, writes the chunk.
*
* 1.6.0: COLORSPACE support controls the writing of these chunks too, and
* the chunks will be written if the WRITE routine is there and information
* is available in the COLORSPACE. (See png_colorspace_sync_info in png.c
* for where the valid flags get set.)
* the chunks will be written if the WRITE routine is there and
* information * is available in the COLORSPACE. (See
* png_colorspace_sync_info in png.c for where the valid flags get set.)
*
* Under certain circumstances the colorspace can be invalidated without
* syncing the info_struct 'valid' flags; this happens if libpng detects and
* error and calls png_error while the color space is being set, yet the
* application continues writing the PNG. So check the 'invalid' flag here
* too.
* syncing the info_struct 'valid' flags; this happens if libpng detects
* an error and calls png_error while the color space is being set, yet
* the * application continues writing the PNG. So check the 'invalid'
* flag here too.
*/
#ifdef PNG_GAMMA_SUPPORTED
# ifdef PNG_WRITE_gAMA_SUPPORTED
@ -1534,10 +1535,11 @@ png_write_image_16bit(png_voidp argument)
++input_row; /* To point to the first component */
++output_row;
}
else
# endif
aindex = channels;
# else
aindex = channels;
# endif
}
else