[libpng16] Control ADLER32 checking with new PNG_IGNORE_ADLER32 option.

This commit is contained in:
Glenn Randers-Pehrson
2016-12-24 16:12:20 -06:00
parent d65a92b951
commit dbb5fce3d8
6 changed files with 30 additions and 22 deletions

View File

@@ -986,9 +986,14 @@ test_one_file(PNG_CONST char *inname, PNG_CONST char *outname)
/* Allow application (pngtest) errors and warnings to pass */
png_set_benign_errors(read_ptr, 1);
/* Turn off CRC and ADLER32 checking while reading */
/* Turn off CRC checking while reading */
png_set_crc_action(read_ptr, PNG_CRC_QUIET_USE, PNG_CRC_QUIET_USE);
#ifdef PNG_IGNORE_ADLER32_SUPPORTED
/* Turn off ADLER32 checking while reading */
png_set_option(read_ptr, PNG_IGNORE_ADLER32, PNG_OPTION_ON);
#endif
# ifdef PNG_WRITE_SUPPORTED
png_set_benign_errors(write_ptr, 1);
# endif