libpng Changelog

What's new in libpng 1.7.0 Beta 52

Feb 23, 2015
  • Added information about setjmp/simplified API interaction in the manual page and INSTALL file. Added information about using row_pointers with a single height*width*bpp allocated block to the manual page.
  • Rebuilt configure scripts with automake-1.15 and libtool-2.4.6

New in libpng 1.7.0 Beta 51 (Feb 23, 2015)

  • Combined similar parts of png_write_find_filter() into a png_increase_lmins()
  • function.
  • Display user limits in the output from pngtest.
  • Replaced test for harmless integer overflow (wraparound) in pngwutil.c with a method that prevents overflow and does not increase cpu usage significantly.

New in libpng 1.7.0 Beta 50 (Feb 23, 2015)

  • Combined sub_row, up_row, avg_row, and paeth_row buffers into a
  • single try_row buffer and in cases where two or more of those are
  • being tested, a second tst_row buffer. This improves CPU speed
  • over that achieved by libpng-1.7.0beta49.

New in libpng 1.7.0 Beta 49 (Feb 12, 2015)

  • Combined sub_row, up_row, avg_row, and paeth_row buffers into a
  • single try_row buffer.
  • Added PNG_WRITE_CUSTOMIZE_COMPRESSION_SUPPORTED macro, on by default.
  • Consolidated redundant code in pngwutil.c
  • Deal with integer overflow of sum in pngwutil.c

New in libpng 1.7.0 Beta 48 (Feb 11, 2015)

  • Work around one more Coverity-scan dead-code warning.
  • Do not build png_product2() when it is unused.

New in libpng 1.7.0 Beta 47 (Jan 29, 2015)

  • Made the check for out-of-range values in png_set_tRNS() detect values that are exactly 2^bit_depth, and work on 16-bit platforms.
  • Added PNG_SKIP_sRGB_CHECK_PROFILE choice for png_set_option().
  • Report all IHDR errors before exiting png_check_IHDR().
  • Merged some parts of libpng-1.6.17beta01 and libpng-1.7.0beta47.
  • Added #ifndef __COVERITY__ where needed in png.c, pngrutil.c and pngset.c to avoid warnings about dead code.

New in libpng 1.7.0 Beta 46 (Jan 10, 2015)

  • Regenerated configure scripts in the tar distributions with libtool-2.4.4
  • Implement previously untested cases of libpng transforms in pngvalid.c
  • Fixed byte order in 2-byte filler, in png_do_read_filler().
  • Allow user to call png_get_IHDR() with NULL arguments

New in libpng 1.7.0 Beta 45 (Dec 29, 2014)

  • Eliminated the PNG_SAFE_LIMITS macro and restored the 1-million-column
  • and 1-million-row default limits in pnglibconf.dfa, that can be reset
  • by the user at build time or run time. This provides a more robust
  • defense against DOS and as-yet undiscovered overflows.
  • Removed user limits from pngfix. Also pass NULL pointers to
  • png_read_row to skip the unnecessary row de-interlace stuff.
  • Added testing of png_set_packing() to pngvalid.c

New in libpng 1.6.16 (Dec 27, 2014)

  • Added ".align 2" to arm/filter_neon.S to support old GAS assemblers that don't do alignment correctly. Revised Makefile.am and scripts/*.dfn to work with MinGW/MSYS; renamed scripts/*.dfn to scripts/*.c (Bob Friesenhahn and John Bowler). Quiet a "comparison always true" warning in pngstest.c (John Bowler). Restored a test on width that was removed from png.c at libpng-1.6.9 (Bug report by Alex Eubanks). Fixed an overflow in png_combine_row with very wide interlaced images.

New in libpng 1.7.0 Beta 44 (Dec 27, 2014)

  • Restored a test on width that was removed from png.c at libpng-1.6.9 (Bug report by Alex Eubanks). Fixed an overflow in png_combine_row with very wide interlaced images. Corrected the width limit calculation in png_check_IHDR(). Removed extraneous handling of PNG_SAFE_LIMITS_SUPPORTED from pngconf.h

New in libpng 1.7.0 Beta 42 (Nov 21, 2014)

  • The macros passed in the command line to Borland make were ignored if similarly-named macros were already defined in makefiles. This behavior is different from POSIX make and other make programs. Surround the macro definitions with ifndef guards (Cosmin).
  • Added "-D_CRT_SECURE_NO_WARNINGS" to CFLAGS in scripts/makefile.vcwin32.
  • Removed the obsolete $ARCH variable from scripts/makefile.darwin.
  • Merged clang no-warning fix from libpng-1.6.13: png_digit was defined but never used in pngerror.c.

New in libpng 1.7.0 Beta 41 (Nov 8, 2014)

  • Added #ifdef PNG_16BIT_SUPPORTED/#endif around png_log16bit() and png_do_swap().

New in libpng 1.6.15 Beta 6 (Nov 7, 2014)

  • Reverted use png_get_libpng_ver(NULL) instead of PNG_LIBPNG_VER_STRING in example.c, pngtest.c, and applications in the contrib directory. It was incorrect advice.

New in libpng 1.6.15 Beta 5 (Nov 6, 2014)

  • Use png_get_libpng_ver(NULL) instead of PNG_LIBPNG_VER_STRING in example.c, pngtest.c, and applications in the contrib directory.
  • Avoid out-of-bounds memory access in png_user_version_check().
  • Simplified and future-proofed png_user_version_check().
  • Fixed GCC unsigned int->float warnings. Various versions of GCC seem to generate warnings when an unsigned value is implicitly converted to double. This is probably a GCC bug but this change avoids the issue by explicitly converting to (int) where safe.
  • Free all allocated memory in pngimage. The file buffer cache was left allocated at the end of the program, harmless but it causes memory leak reports from clang.
  • Fixed array size calculations to avoid warnings. At various points in the code the number of elements in an array is calculated using sizeof. This generates a compile time constant of type (size_t) which is then typically assigned to an (unsigned int) or (int). Some versions of GCC on 64-bit systems warn about the apparent narrowing, even though the same compiler does apparently generate the correct, in-range, numeric constant. This adds appropriate, safe, casts to make the warnings go away.

New in libpng 1.6.15 Beta 4 (Nov 5, 2014)

  • Removed new PNG_USE_ARM_NEON configuration flag and made a one-line revision to configure.ac to support ARM on aarch64 instead (John Bowler).

New in libpng 1.6.15 Beta 3 (Nov 4, 2014)

  • Added PNG_USE_ARM_NEON configuration flag

New in libpng 1.6.15 Beta 2 (Nov 3, 2014)

  • Changed remaining "if (!x)" to "if (x == 0)" and "if (x)" to "if (x !== 0)"

New in libpng 1.7.0 Beta 39 (Nov 3, 2014)

  • Ported cosmetic changes from libpng-1.6.15beta02.

New in libpng 1.6.15 Beta 1 (Oct 30, 2014)

  • Changed "if (!x)" to "if (x == 0)" and "if (x)" to "if (x !== 0)"
  • Simplified png_free_data().
  • Added missing "ptr = NULL" after some instances of png_free().

New in libpng 1.6.14 RC 02 (Oct 18, 2014)

  • Changed png_convert_to_rfc_1123() to png_convert_to_rfc_1123_buffer() in the manual, to reflect the change made in libpng-1.6.0.

New in libpng 1.6.14 RC 01 (Oct 17, 2014)

  • Fixed some typos in comments.

New in libpng 1.7.0 Beta 36 (Sep 30, 2014)

  • Updated scripts/makefiles from libpng-1.6.13beta04.

New in libpng 1.7.0 Beta 35 (Aug 11, 2014)

  • Removed #if/#else/#endif from inside two pow() calls in pngvalid.c because they were handled improperly by Portland Group's PGI-14.1 - PGI-14.3 when using its "__builtin_pow()" function.
  • Silence 'unused parameter' build warnings (Cosmin).
  • $(CP) is now used alongside $(RM_F). Also, use 'copy' instead of 'cp' where applicable, and applied other minor makefile changes.
  • Don't warn about invalid dimensions exceeding user limits.
  • Allow an easy replacement of the default pre-built configuration header with a custom header, via the make PNGLIBCONF_H_PREBUILT macro.
  • Fixed a typo in pngrutil.c, introduced in libpng-1.5.6, that interferes with "blocky" expansion of sub-8-bit interlaced PNG files (Eric Huss).
  • Removed scripts/makefile.elf. It has not worked since libpng-1.5.0beta14 due to elimination of the PNG_FUNCTION_EXPORT and PNG_DATA_EXPORT definitions from pngconf.h.
  • Ensure that CMakeLists.txt makes the target "lib" directory before making symbolic link into it (SourceForge bug report #226 by Rolf Timmermans).

New in libpng 1.7.0 Beta 34 (Aug 4, 2014)

  • Treat CRC error handling with png_set_crc_action(), instead of with png_set_benign_errors(), which has been the case since libpng-1.6.0beta18.
  • Use "if (value != 0)" instead of "if (value)" consistently.
  • Changed ZlibSrcDir from 1.2.5 to 1.2.8 in projects/vstudio.
  • Moved configuration information from the manual to the INSTALL file.

New in libpng 1.6.13 Beta 02 (Jul 22, 2014)

  • Fixed an incorrect separator ("/" should be "\") in scripts/makefile.vcwin32(bug report from Wolfgang S. Kechel). Bug was introduced in libpng-1.6.11.
  • Also fixed makefile.bc32, makefile.bor, makefile.msc, makefile.intel, and makefile.tc3 similarly.

New in libpng 1.6.13 Beta 01 (Jul 22, 2014)

  • Quieted -Wsign-compare and -Wclobber compiler warnings in contrib/pngminus/*.c
  • Added "(void) png_ptr;" where needed in contrib/gregbook to quiet compiler complaints about unused pointers.
  • Split a long output string in contrib/gregbook/rpng2-x.c.
  • Added "PNG_SET_OPTION" requirement for sRGB chunk support to pnglibconf.dfa, Needed for write-only support (John Bowler).
  • Changed "if defined(__ARM_NEON__)" to "if (defined(__ARM_NEON__) || defined(__ARM_NEON))" (James Wu).
  • Fixed clang no-warning builds: png_digit was defined but never used.

New in libpng 1.6.5 (Sep 16, 2013)

  • Removed two stray lines of code from arm/arm_init.c.

New in libpng 1.6.3 (Jul 25, 2013)

  • Revised manual about changes in iTXt chunk handling made in libpng-1.6.0.
  • Added "/* SAFE */" comments in pngrutil.c and pngrtran.c where warnings may be erroneously issued by code-checking applications.

New in libpng 1.5.12 (Jul 12, 2012)

  • Removed scripts/makefile.cegcc from the *.zip and *.7z distributions; it depends on configure, which is not included in those archives.
  • Changed "a+w" to "u+w" in Makefile.in to fix CVE-2012-3386.

New in libpng 1.5.5 (Sep 22, 2011)

  • Fixed some typos and made other minor changes in the manual.
  • Updated contrib/pngminus/makefile.std (Samuli Souminen)
  • Revised Makefile.am and Makefile.in to look in the right directory for pnglibconf.h.prebuilt Enabled compilation with g++ compiler.
  • This compiler does not recognize the file extension, so it always compiles with C++ rules.
  • Made minor changes to pngrutil.c to cast results where C++ expects it but C does not.
  • Minor editing of libpng.3 and libpng-manual.txt.
  • Revised CMakeLists.txt (Clifford Yapp) Updated commentary about the png_rgb_to_gray() default coefficients in the manual and in pngrtran.c
  • Prevent unexpected API exports from non-libpng DLLs on Windows. The "_DLL" is removed from the test of whether a DLL is being built (this erroneously caused the libpng APIs to be marked as DLL exports in static builds under Microsoft Visual Studio).
  • Almost all of the libpng building configuration is moved from pngconf.h to pngpriv.h, but PNG_DLL_EXPORT remains in pngconf.h, though, so that it is colocated with the import definition (it is no longer used anywhere in the installed headers).
  • The VStudio project definitions have been cleaned up: "_USRDLL" has been removed from the static library builds (this was incorrect), and PNG_USE_DLL has been added to pngvalid to test the functionality (pngtest does not supply it, deliberately).
  • The spurious "_EXPORTS" has been removed from the libpng build (all these errors were a result of copy/paste between project configurations.)
  • Added new types and internal functions for CIE RGB end point handling to pngpriv.h (functions yet to be implemented).
  • Ensure the CMAKE_LIBRARY_OUTPUT_DIRECTORY is set in CMakeLists.txt (Clifford Yap)
  • Fixes to rgb_to_gray and cHRM XYZ APIs (John Bowler): The rgb_to_gray code had errors when combined with gamma correction.
  • Some pixels were treated as true grey when they weren't and such pixels and true grey ones were not gamma corrected (the original value of the red component was used instead).
  • APIs to get and set cHRM using color space end points have been added and the rgb_to_gray code that defaults based on cHRM, and the divide-by-zero bug in png_handle_cHRM (CERT VU#477046, CVE-2011-3328, introduced in 1.5.4) have been corrected.
  • A considerable number of tests has been added to pngvalid for the rgb_to_gray transform. Arithmetic errors in rgb_to_gray whereby the calculated gray value was truncated to the bit depth rather than rounded have been fixed except in the 8-bit non-gamma-corrected case (where consistency seems more important than correctness.)
  • The code still has considerable inaccuracies in the 8-bit case because 8-bit linear arithmetic is used.
  • Added "$(ARCH)" option to makefile.darwin
  • Added SunOS support to configure.ac and Makefile.am
  • Changed png_chunk_benign_error() to png_warning() in png.c, in png_XYZ_from_xy_checked(). Fixed 64-bit compilation errors (gcc).
  • The errors fixed relate to conditions where types that are 32 bits in the GCC 32-bit world (uLong and png_size_t) become 64 bits in the 64-bit world. This produces potential truncation errors that the compiler correctly flags. Constant changes for 64-bit compatibility (removal of L suffixes). The 16-bit cases still use "L" as we don't have a 16-bit test system.

New in libpng 1.5.3 Beta 02 (Apr 11, 2011)

  • Updated scripts/symbols.def with new API functions.
  • Only compile the new zlib re-initializing code when text or iCCP is supported, using PNG_WRITE_COMPRESSED_TEXT_SUPPORTED macro.
  • Improved the optimization of the zlib CMF byte (see libpng-1.2.6beta03).
  • Optimize the zlib CMF byte in non-IDAT compressed chunks.

New in libpng 1.5.0 Beta 45 (Aug 26, 2010)

  • Added an explicit make step to projects/vstudio for pnglibconf.h
  • Also corrected zlib.vcxproj into which Visual Studio had introduced
  • what it calls an "authoring error". The change to make pnglibconf.h
  • simply copies the file; in the future it may actually generate the
  • file from scripts/pnglibconf.dfa as the other build systems do.
  • Changed pngvalid to work when floating point APIs are disabled
  • Renamed the prebuilt scripts/pnglibconf.h to scripts/pnglibconf.h.prebuilt
  • Supply default values for PNG_USER_PRIVATEBUILD and PNG_USER_DLLFNAME_POSTFIX in pngpriv.h in case the user neglected to define them in their pngusr.h

New in libpng 1.5.0 Beta 39 (Aug 2, 2010)

  • VisualC/GCC warning fixes, VisualC build fixes
  • The changes include support for function attributes in VC in addition to those already present in GCC - necessary because without these some warnings are unavoidable. Fixes include signed/unsigned fixes in pngvalid and checks with gcc -Wall -Wextra -Wunused.
  • VC requires function attributes on function definitions as well as declarations, PNG_FUNCTION has been added to enable this and the relevant function definitions changed.

New in libpng 1.4.1 RC02 (Feb 18, 2010)

  • Makefile.am need only be changed on a major version number
  • change (e.g. libpng12 --> libpng13). In that case seach
  • this file for every instance of the old base name (libpng12)
  • and change to the new one (libpng13), then change the
  • version-number settings below so that the new values have
  • the correct major part (first field)

New in libpng 1.4.0 Beta 67 (Jul 16, 2009)

  • Added xcode project.
  • Added GRAY_TO_RGB transform to the high-level API.

New in libpng 1.2.38 (Jul 16, 2009)

  • Rebuilt configuration files with autoconf-2.63.
  • Revised license declarations to read "libpng license"
  • Revised conditional compilation of unknown chunk support.

New in libpng 1.2.37 (Jul 6, 2009)

  • Fixed bug with new png_memset() of the big_row_buffer.
  • Otherwise the changes are extensive but just cosmetic.

New in libpng 1.4.0 Beta 61 (May 28, 2009)

  • Cosmetic changes to source to make comments and indentation consistent with libpng style, mostly capitalization of sentences in the comments.

New in libpng 1.4.0 Beta 57 (May 11, 2009)

  • Built config scripts with autoconf 2.62
  • Removed support of pngdefs.h from makerfiles
  • Removed a stray prototype for png_freeptr() that was never defined.

New in libpng 1.2.35 (Feb 21, 2009)

  • Fixes vulnerability with uninitialized pointer arrays.

New in libpng 1.2.34 (Dec 18, 2008)

  • Avoid potential double-free in png_check_keyword().

New in libpng 1.2.34 Beta 7 (Dec 11, 2008)

  • Added PNG_TRANSFORM_STRIP_FILLER_BEFORE and PNG_TRANSFORM_STRIP_FILLER_AFTER macros and deprecated PNG_TRANSFORM_STRIP_FILLER.

New in libpng 1.2.34 Beta 2 (Dec 1, 2008)

  • Fixed off-by-one error in bKGD chunk validity checking for paletted PNG images.

New in libpng 1.2.33 (Dec 1, 2008)

  • Fix memory leak when reading malformed tEXt chunk.