[libpng16] Use zlib-1.2.8.1 inflateValidate() instead of inflateReset2() to

avoid ADLER32 evaluation.
This commit is contained in:
Glenn Randers-Pehrson
2016-10-07 13:33:50 -05:00
parent ffaeff82d3
commit a106899acd
3 changed files with 9 additions and 5 deletions

View File

@@ -418,10 +418,10 @@ png_inflate_claim(png_structrp png_ptr, png_uint_32 owner)
png_ptr->flags |= PNG_FLAG_ZSTREAM_INITIALIZED;
}
#if ZLIB_VERNUM >= 0x1240
#if ZLIB_VERNUM >= 0x1281
/* Turn off validation of the ADLER32 checksum */
if ((png_ptr->flags & PNG_FLAG_CRC_CRITICAL_IGNORE) != 0)
ret = inflateReset2(&png_ptr->zstream, -window_bits);
ret = inflateValidate(&png_ptr->zstream, 0);
#endif
if (ret == Z_OK)