[libpng17] Check for info_ptr == NULL early in png_read_end() so we don't need

to run all the png_handle_*() and depend on them to return if info_ptr == NULL.
This improves the performance of png_read_end(png_ptr, NULL) and makes
it more robust against future programming errors.
This commit is contained in:
Glenn Randers-Pehrson
2014-02-17 11:53:35 -06:00
parent 2ced844b0e
commit 848eeacb41
4 changed files with 18 additions and 7 deletions

View File

@@ -1,5 +1,5 @@
Libpng 1.7.0beta32 - February 16, 2014
Libpng 1.7.0beta32 - February 17, 2014
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.
@@ -533,7 +533,7 @@ Version 1.7.0beta31 [February 6, 2014]
and it adds corresponding code to pngimage.c to handle such options
by not attempting to test them.
Version 1.7.0beta32 [February 16, 2014]
Version 1.7.0beta32 [February 17, 2014]
Moved redefines of png_error(), png_warning(), png_chunk_error(),
and png_chunk_warning() from pngpriv.h to png.h to make them visible
to libpng-calling applications.
@@ -544,6 +544,10 @@ Version 1.7.0beta32 [February 16, 2014]
compile and link on Android by using /proc/cpuinfo, and the old linux code
is in contrib/arm-neon/linux-auxv.c. The new code avoids POSIX and Linux
dependencies apart from opening /proc/cpuinfo and is C90 compliant.
Check for info_ptr == NULL early in png_read_end() so we don't need to
run all the png_handle_*() and depend on them to return if info_ptr == NULL.
This improves the performance of png_read_end(png_ptr, NULL) and makes
it more robust against future programming errors.
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
(subscription required; visit