Author: akhaldi
Date: Wed Apr 20 09:00:52 2016
New Revision: 71182
URL:
http://svn.reactos.org/svn/reactos?rev=71182&view=rev
Log:
[LIBPNG] Update to v1.6.21. CORE-11128
Modified:
trunk/reactos/dll/3rdparty/libpng/docs/ANNOUNCE
trunk/reactos/dll/3rdparty/libpng/docs/CHANGES
trunk/reactos/dll/3rdparty/libpng/docs/LICENSE
trunk/reactos/dll/3rdparty/libpng/docs/README
trunk/reactos/dll/3rdparty/libpng/docs/libpng-manual.txt
trunk/reactos/dll/3rdparty/libpng/png.c
trunk/reactos/dll/3rdparty/libpng/pngdebug.h
trunk/reactos/dll/3rdparty/libpng/pngerror.c
trunk/reactos/dll/3rdparty/libpng/pngget.c
trunk/reactos/dll/3rdparty/libpng/pnginfo.h
trunk/reactos/dll/3rdparty/libpng/pngmem.c
trunk/reactos/dll/3rdparty/libpng/pngpread.c
trunk/reactos/dll/3rdparty/libpng/pngpriv.h
trunk/reactos/dll/3rdparty/libpng/pngread.c
trunk/reactos/dll/3rdparty/libpng/pngrio.c
trunk/reactos/dll/3rdparty/libpng/pngrtran.c
trunk/reactos/dll/3rdparty/libpng/pngrutil.c
trunk/reactos/dll/3rdparty/libpng/pngset.c
trunk/reactos/dll/3rdparty/libpng/pngstruct.h
trunk/reactos/dll/3rdparty/libpng/pngtrans.c
trunk/reactos/dll/3rdparty/libpng/pngwio.c
trunk/reactos/dll/3rdparty/libpng/pngwrite.c
trunk/reactos/dll/3rdparty/libpng/pngwtran.c
trunk/reactos/dll/3rdparty/libpng/pngwutil.c
trunk/reactos/include/reactos/libs/libpng/png.h
trunk/reactos/include/reactos/libs/libpng/pngconf.h
trunk/reactos/include/reactos/libs/libpng/pnglibconf.h
trunk/reactos/media/doc/3rd Party Files.txt
Modified: trunk/reactos/dll/3rdparty/libpng/docs/ANNOUNCE
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/docs/A…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/docs/ANNOUNCE [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/docs/ANNOUNCE [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,4 +1,4 @@
-Libpng 1.6.19 - November 12, 2015
+Libpng 1.6.21 - January 15, 2016
This is a public release of libpng, intended for use in production codes.
@@ -7,104 +7,49 @@
Source files with LF line endings (for Unix/Linux) and with a
"configure" script
- libpng-1.6.19.tar.xz (LZMA-compressed, recommended)
- libpng-1.6.19.tar.gz
+ libpng-1.6.21.tar.xz (LZMA-compressed, recommended)
+ libpng-1.6.21.tar.gz
Source files with CRLF line endings (for Windows), without the
"configure" script
- lpng1619.7z (LZMA-compressed, recommended)
- lpng1619.zip
+ /scratch/glennrp/Libpng16/lpng1621.7z (LZMA-compressed, recommended)
+ /scratch/glennrp/Libpng16/lpng1621.zip
Other information:
- libpng-1.6.19-README.txt
- libpng-1.6.19-LICENSE.txt
- libpng-1.6.19-*.asc (armored detached GPG signatures)
+ libpng-1.6.21-README.txt
+ libpng-1.6.21-LICENSE.txt
+ libpng-1.6.21-*.asc (armored detached GPG signatures)
-Changes since the last public release (1.6.18):
+Changes since the last public release (1.6.20):
- Updated obsolete information about the simplified API macros in the
- manual pages (Bug report by Arc Riley).
- Avoid potentially dereferencing NULL info_ptr in png_info_init_3().
- Rearranged png.h to put the major sections in the same order as
- in libpng17.
- Eliminated unused PNG_COST_SHIFT, PNG_WEIGHT_SHIFT, PNG_COST_FACTOR, and
- PNG_WEIGHT_FACTOR macros.
- Suppressed some warnings from the Borland C++ 5.5.1/5.82 compiler
- (Bug report by Viktor Szakats). Several warnings remain and are
- unavoidable, where we test for overflow.
- Fixed potential leak of png_pixels in contrib/pngminus/pnm2png.c
- Fixed uninitialized variable in contrib/gregbook/rpng2-x.c
- Moved config.h.in~ from the "libpng_autotools_files" list to the
- "libpng_autotools_extra" list in autogen.sh because it was causing a
- false positive for missing files (bug report by Robert C. Seacord).
- Removed unreachable "break" statements in png.c, pngread.c, and pngrtran.c
- to suppress clang warnings (Bug report by Viktor Szakats).
- Fixed some bad links in the man page.
- Changed "n bit" to "n-bit" in comments.
- Added signed/unsigned 16-bit safety net. This removes the dubious
- 0x8000 flag definitions on 16-bit systems. They aren't supported
- yet the defs *probably* work, however it seems much safer to do this
- and be advised if anyone, contrary to advice, is building libpng 1.6
- on a 16-bit system. It also adds back various switch default clauses
- for GCC; GCC errors out if they are not present (with an appropriately
- high level of warnings).
- Safely convert num_bytes to a png_byte in png_set_sig_bytes() (Robert
- Seacord).
- Fixed the recently reported 1's complement security issue by replacing
- the value that is illegal in the PNG spec, in both signed and unsigned
- values, with 0. Illegal unsigned values (anything greater than or equal
- to 0x80000000) can still pass through, but since these are not illegal
- in ANSI-C (unlike 0x80000000 in the signed case) the checking that
- occurs later can catch them (John Bowler).
- Fixed png_save_int_32 when int is not 2's complement (John Bowler).
- Updated libpng16 with all the recent test changes from libpng17,
- including changes to pngvalid.c to ensure that the original,
- distributed, version of contrib/visupng/cexcept.h can be used
- (John Bowler).
- pngvalid contains the correction to the use of SAVE/STORE_
- UNKNOWN_CHUNKS; a bug revealed by changes in libpng 1.7. More
- tests contain the --strict option to detect warnings and the
- pngvalid-standard test has been corrected so that it does not
- turn on progressive-read. There is a separate test which does
- that. (John Bowler)
- Also made some signed/unsigned fixes.
- Make pngstest error limits version specific. Splitting the machine
- generated error structs out to a file allows the values to be updated
- without changing pngstest.c itself. Since libpng 1.6 and 1.7 have
- slightly different error limits this simplifies maintenance. The
- makepngs.sh script has also been updated to more accurately reflect
- current problems in libpng 1.7 (John Bowler).
- Incorporated new test PNG files into make check. tests/pngstest-*
- are changed so that the new test files are divided into 8 groups by
- gamma and alpha channel. These tests have considerably better code
- and pixel-value coverage than contrib/pngsuite; however,coverage is
- still incomplete (John Bowler).
- Removed the '--strict' in 1.6 because of the double-gamma-correction
- warning, updated pngstest-errors.h for the errors detected with the
- new contrib/testspngs PNG test files (John Bowler).
- Worked around rgb-to-gray issues in libpng 1.6. The previous
- attempts to ignore the errors in the code aren't quite enough to
- deal with the 'channel selection' encoding added to libpng 1.7; abort.
- Fixed 'pow' macros in pngvalid.c. It is legal for 'pow' to be a
- macro, therefore the argument list cannot contain preprocessing
- directives. Make sure pow is a function where this happens. This is
- a minimal safe fix, the issue only arises in non-performance-critical
- code (bug report by Curtis Leach, fix by John Bowler).
- Added sPLT support to pngtest.c
- Prevent setting or writing over-length PLTE chunk (Cosmin Truta).
- Silently truncate over-length PLTE chunk while reading.
- Libpng incorrectly calculated the output rowbytes when the application
- decreased either the number of channels or the bit depth (or both) in
- a user transform. This was safe; libpng overallocated buffer space
- (potentially by quite a lot; up to 4 times the amount required) but,
- from 1.5.4 on, resulted in a png_error (John Bowler).
- Fixed some inconsequential cut-and-paste typos in png_set_cHRM_XYZ_fixed().
- Clarified COPYRIGHT information to state explicitly that versions
- are derived from previous versions.
- Removed much of the long list of previous versions from png.h and
- libpng.3.
+ Fixed syntax "$(command)" in tests/pngstest that some shells other than
+ bash could not parse (Bug report by Nelson Beebe). Use `command` instead.
+ Moved png_check_keyword() from pngwutil.c to pngset.c
+ Removed LE/BE dependencies in pngvalid, to 'fix' the current problem
+ in the BigEndian tests by not testing it, making the BE code the same
+ as the LE version.
+ Fixes to pngvalid for various reduced build configurations (eliminate unused
+ statics) and a fix for the case in rgb_to_gray when the digitize option
+ reduces graylo to 0, producing a large error.
+ Widened the 'limit' check on the internally calculated error limits in
+ the 'DIGITIZE' case (the code used prior to 1.7 for rgb_to_gray error
+ checks) and changed the check to only operate in non-release builds
+ (base build type not RC or RELEASE.)
+ Fixed undefined behavior in pngvalid.c, undefined because
+ (png_byte) << shift is undefined if it changes the signed bit
+ (because png_byte is promoted to int). The libpng exported functions
+ png_get_uint_32 and png_get_uint_16 handle this. (Bug reported by
+ David Drysdale as a result of reports from UBSAN in clang 3.8).
+ This changes pngvalid to use BE random numbers; this used to produce
+ errors but these should not be fixed as a result of the previous changes.
+ In projects/vstudio, combined readme.txt and WARNING into README.txt
+ Relocated assert() in contrib/tools/pngfix.c, bug found by American
+ Fuzzy Lop, reported by Brian Carpenter.
+ Marked 'limit' UNUSED in transform_range_check(). This only affects
+ release builds.
+ Worked around a false-positive Coverity issue in pngvalid.c.
Send comments/corrections/commendations to png-mng-implement at
lists.sf.net
(subscription required; visit
Modified: trunk/reactos/dll/3rdparty/libpng/docs/CHANGES
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/docs/C…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/docs/CHANGES [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/docs/CHANGES [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -5409,10 +5409,80 @@
Version 1.6.19rc04 [November 5, 2015]
Fixed new bug with CRC error after reading an over-length palette
- (bug report by Cosmin Truta).
+ (bug report by Cosmin Truta) (CVE-2015-8126).
Version 1.6.19 [November 12, 2015]
Cleaned up coding style in png_handle_PLTE().
+
+Version 1.6.20beta01 [November 20, 2015]
+ Avoid potential pointer overflow/underflow in png_handle_sPLT() and
+ png_handle_pCAL() (Bug report by John Regehr).
+
+Version 1.6.20beta02 [November 23, 2015]
+ Fixed incorrect implementation of png_set_PLTE() that uses png_ptr
+ not info_ptr, that left png_set_PLTE() open to the CVE-2015-8126
+ vulnerability. Fixes CVE-2015-8472.
+
+Version 1.6.20beta03 [November 24, 2015]
+ Backported tests from libpng-1.7.0beta69.
+
+Version 1.6.20rc01 [November 26, 2015]
+ Fixed an error in handling of bad zlib CMINFO field in pngfix, found by
+ American Fuzzy Lop, reported by Brian Carpenter. inflate() doesn't
+ immediately fault a bad CMINFO field; instead a 'too far back' error
+ happens later (at least some times). pngfix failed to limit CMINFO to
+ the allowed values but then assumed that window_bits was in range,
+ triggering an assert. The bug is mostly harmless; the PNG file cannot
+ be fixed.
+
+Version 1.6.20rc02 [November 29, 2015]
+ In libpng 1.6 zlib initialization was changed to use the window size
+ in the zlib stream, not a fixed value. This causes some invalid images,
+ where CINFO is too large, to display 'correctly' if the rest of the
+ data is valid. This provides a workaround for zlib versions where the
+ error arises (ones that support the API change to use the window size
+ in the stream).
+
+Version 1.6.20 [December 3, 2015]
+ No changes.
+
+Version 1.6.21beta01 [December 11, 2015]
+ Fixed syntax "$(command)" in tests/pngstest that some shells other than
+ bash could not parse (Bug report by Nelson Beebe). Use `command` instead.
+
+Version 1.6.21beta02 [December 14, 2015]
+ Moved png_check_keyword() from pngwutil.c to pngset.c
+ Removed LE/BE dependencies in pngvalid, to 'fix' the current problem
+ in the BigEndian tests by not testing it, making the BE code the same
+ as the LE version.
+ Fixes to pngvalid for various reduced build configurations (eliminate unused
+ statics) and a fix for the case in rgb_to_gray when the digitize option
+ reduces graylo to 0, producing a large error.
+
+Version 1.6.21beta03 [December 18, 2015]
+ Widened the 'limit' check on the internally calculated error limits in
+ the 'DIGITIZE' case (the code used prior to 1.7 for rgb_to_gray error
+ checks) and changed the check to only operate in non-release builds
+ (base build type not RC or RELEASE.)
+ Fixed undefined behavior in pngvalid.c, undefined because
+ (png_byte) << shift is undefined if it changes the signed bit
+ (because png_byte is promoted to int). The libpng exported functions
+ png_get_uint_32 and png_get_uint_16 handle this. (Bug reported by
+ David Drysdale as a result of reports from UBSAN in clang 3.8).
+ This changes pngvalid to use BE random numbers; this used to produce
+ errors but these should not be fixed as a result of the previous changes.
+
+Version 1.6.21rc01 [January 4, 2016]
+ In projects/vstudio, combined readme.txt and WARNING into README.txt
+
+Version 1.6.21rc02 [January 7, 2016]
+ Relocated assert() in contrib/tools/pngfix.c, bug found by American
+ Fuzzy Lop, reported by Brian Carpenter.
+ Marked 'limit' UNUSED in transform_range_check(). This only affects
+ release builds.
+
+Version 1.6.21 [January 15, 2016]
+ Worked around a false-positive Coverity issue in pngvalid.c.
Send comments/corrections/commendations to png-mng-implement at
lists.sf.net
(subscription required; visit
Modified: trunk/reactos/dll/3rdparty/libpng/docs/LICENSE
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/docs/L…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/docs/LICENSE [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/docs/LICENSE [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -10,8 +10,8 @@
This code is released under the libpng license.
-libpng versions 1.0.7, July 1, 2000, through 1.6.19, November 12, 2015, are
-Copyright (c) 2000-2002, 2004, 2006-2015 Glenn Randers-Pehrson, are
+libpng versions 1.0.7, July 1, 2000, through 1.6.21, January 15, 2016, are
+Copyright (c) 2000-2002, 2004, 2006-2016 Glenn Randers-Pehrson, are
derived from libpng-1.0.6, and are distributed according to the same
disclaimer and license as libpng-1.0.6 with the following individuals
added to the list of Contributing Authors:
@@ -109,4 +109,4 @@
Glenn Randers-Pehrson
glennrp at
users.sourceforge.net
-November 12, 2015
+January 15, 2016
Modified: trunk/reactos/dll/3rdparty/libpng/docs/README
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/docs/R…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/docs/README [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/docs/README [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,4 +1,4 @@
-README for libpng version 1.6.19 - November 12, 2015 (shared library 16.0)
+README for libpng version 1.6.21 - January 15, 2016 (shared library 16.0)
See the note about version numbers near the top of png.h
See INSTALL for instructions on how to install libpng.
Modified: trunk/reactos/dll/3rdparty/libpng/docs/libpng-manual.txt
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/docs/l…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/docs/libpng-manual.txt [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/docs/libpng-manual.txt [iso-8859-1] Wed Apr 20
09:00:52 2016
@@ -1,9 +1,9 @@
libpng-manual.txt - A description on how to use and modify libpng
- libpng version 1.6.19 - November 12, 2015
+ libpng version 1.6.21 - January 15, 2016
Updated and distributed by Glenn Randers-Pehrson
<glennrp at users.sourceforge.net>
- Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ Copyright (c) 1998-2016 Glenn Randers-Pehrson
This document is released under the libpng license.
For conditions of distribution and use, see the disclaimer
@@ -11,9 +11,9 @@
Based on:
- libpng versions 0.97, January 1998, through 1.6.19 - November 12, 2015
+ libpng versions 0.97, January 1998, through 1.6.21 - January 15, 2016
Updated and distributed by Glenn Randers-Pehrson
- Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ Copyright (c) 1998-2016 Glenn Randers-Pehrson
libpng 1.0 beta 6 - version 0.96 - May 28, 1997
Updated and distributed by Andreas Dilger
@@ -2959,6 +2959,7 @@
palette - the palette for the file
(array of png_color)
num_palette - number of entries in the palette
+
png_set_gAMA(png_ptr, info_ptr, file_gamma);
png_set_gAMA_fixed(png_ptr, info_ptr, int_file_gamma);
@@ -4897,7 +4898,7 @@
application calls to png_set_user_limits(), png_set_user_chunk_cache_max(),
and/or png_set_user_malloc_max() that increase or decrease the limits. Also,
in libpng-1.5.10 the default width and height limits were increased
-from 1,000,000 to 0x7ffffff (i.e., made unlimited). Therefore, the
+from 1,000,000 to 0x7fffffff (i.e., made unlimited). Therefore, the
limits are now
default safe
png_user_width_max 0x7fffffff 1,000,000
@@ -5077,6 +5078,10 @@
and is interpreted by libpng to convey a one-tracer-curve gray profile or a
three-tracer-curve RGB profile as appropriate.
+Libpng 1.5.x erroneously used /MD for Debug DLL builds; if you used the debug
+builds in your app and you changed your app to use /MD you will need to
+change it back to /MDd for libpng 1.6.x.
+
Prior to libpng-1.6.0 a warning would be issued if the iTXt chunk contained
an empty language field or an empty translated keyword. Both of these
are allowed by the PNG specification, so these warnings are no longer issued.
@@ -5323,7 +5328,7 @@
an official declaration.
This is your unofficial assurance that libpng from version 0.71 and
-upward through 1.6.19 are Y2K compliant. It is my belief that earlier
+upward through 1.6.21 are Y2K compliant. It is my belief that earlier
versions were also Y2K compliant.
Libpng only has two year fields. One is a 2-byte unsigned integer
Modified: trunk/reactos/dll/3rdparty/libpng/png.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/png.c?…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/png.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/png.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* png.c - location for general purpose libpng functions
*
* Last changed in libpng 1.6.19 [November 12, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -14,7 +14,7 @@
#include "pngpriv.h"
/* Generate a compiler error if there is an old png.h in the search path. */
-typedef png_libpng_version_1_6_19 Your_png_h_is_not_version_1_6_19;
+typedef png_libpng_version_1_6_21 Your_png_h_is_not_version_1_6_21;
/* Tells libpng that we have already handled the first "num_bytes" bytes
* of the PNG file signature. If the PNG data is embedded into another
@@ -775,14 +775,15 @@
#else
# ifdef __STDC__
return PNG_STRING_NEWLINE \
- "libpng version 1.6.19 - November 12, 2015" PNG_STRING_NEWLINE \
- "Copyright (c) 1998-2015 Glenn Randers-Pehrson" PNG_STRING_NEWLINE \
+ "libpng version 1.6.21 - January 15, 2016" PNG_STRING_NEWLINE \
+ "Copyright (c) 1998-2002,2004,2006-2016 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.19 - November 12, 2015\
- Copyright (c) 1998-2015 Glenn Randers-Pehrson\
+ return "libpng version 1.6.21 - January 15, 2016\
+ Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson\
Copyright (c) 1996-1997 Andreas Dilger\
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.";
# endif
@@ -2343,7 +2344,7 @@
* Fall through to "no match".
*/
png_chunk_report(png_ptr,
- "Not recognizing known sRGB profile that has been edited",
+ "Not recognizing known sRGB profile that has been edited",
PNG_CHUNK_WARNING);
break;
# endif
Modified: trunk/reactos/dll/3rdparty/libpng/pngdebug.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngdeb…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngdebug.h [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngdebug.h [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngdebug.h - Debugging macros for libpng, also used in pngtest.c
*
* Last changed in libpng 1.6.8 [December 19, 2013]
- * Copyright (c) 1998-2013 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2013 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngerror.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngerr…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngerror.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngerror.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngerror.c - stub functions for i/o and memory allocation
*
* Last changed in libpng 1.6.15 [November 20, 2014]
- * Copyright (c) 1998-2014 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2014 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -768,7 +768,7 @@
/* If control reaches this point, png_longjmp() must not return. The only
* choice is to terminate the whole process (or maybe the thread); to do
- * this the ANSI-C abort() function is used unless a different method is
+ * this the ANSI-C abort() function is used unless a different method is
* implemented by overriding the default configuration setting for
* PNG_ABORT().
*/
Modified: trunk/reactos/dll/3rdparty/libpng/pngget.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngget…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngget.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngget.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngget.c - retrieval of values from info struct
*
* Last changed in libpng 1.6.17 [March 26, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pnginfo.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pnginf…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pnginfo.h [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pnginfo.h [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pnginfo.h - header file for PNG reference library
*
* Last changed in libpng 1.6.1 [March 28, 2013]
- * Copyright (c) 1998-2013 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2013 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -223,7 +223,7 @@
/* Storage for unknown chunks that the library doesn't recognize. */
png_unknown_chunkp unknown_chunks;
- /* The type of this field is limited by the type of
+ /* The type of this field is limited by the type of
* png_struct::user_chunk_cache_max, else overflow can occur.
*/
int unknown_chunks_num;
Modified: trunk/reactos/dll/3rdparty/libpng/pngmem.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngmem…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngmem.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngmem.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngmem.c - stub functions for memory allocation
*
* Last changed in libpng 1.6.15 [November 20, 2014]
- * Copyright (c) 1998-2014 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2014 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngpread.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngpre…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngpread.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngpread.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngpread.c - read a png file in push mode
*
* Last changed in libpng 1.6.18 [July 23, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -133,7 +133,7 @@
void /* PRIVATE */
png_push_read_sig(png_structrp png_ptr, png_inforp info_ptr)
{
- png_size_t num_checked = png_ptr->sig_bytes, /* SAFE, does not exceed 8 */
+ png_size_t num_checked = png_ptr->sig_bytes, /* SAFE, does not exceed 8 */
num_to_check = 8 - num_checked;
if (png_ptr->buffer_size < num_to_check)
@@ -662,7 +662,7 @@
* change the current behavior (see comments in inflate.c
* for why this doesn't happen at present with zlib 1.2.5).
*/
- ret = inflate(&png_ptr->zstream, Z_SYNC_FLUSH);
+ ret = PNG_INFLATE(png_ptr, Z_SYNC_FLUSH);
/* Check for any failure before proceeding. */
if (ret != Z_OK && ret != Z_STREAM_END)
Modified: trunk/reactos/dll/3rdparty/libpng/pngpriv.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngpri…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngpriv.h [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngpriv.h [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,8 +1,8 @@
/* pngpriv.h - private declarations for use inside libpng
*
- * Last changed in libpng 1.6.18 [July 23, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Last changed in libpng 1.6.21 [January 15, 2016]
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -1217,6 +1217,14 @@
/* Initialize the row buffers, etc. */
PNG_INTERNAL_FUNCTION(void,png_read_start_row,(png_structrp png_ptr),PNG_EMPTY);
+#if PNG_ZLIB_VERNUM >= 0x1240
+PNG_INTERNAL_FUNCTION(int,png_zlib_inflate,(png_structrp png_ptr, int flush),
+ PNG_EMPTY);
+# define PNG_INFLATE(pp, flush) png_zlib_inflate(pp, flush)
+#else /* Zlib < 1.2.4 */
+# define PNG_INFLATE(pp, flush) inflate(&(pp)->zstream, flush)
+#endif /* Zlib < 1.2.4 */
+
#ifdef PNG_READ_TRANSFORMS_SUPPORTED
/* Optional call to update the users info structure */
PNG_INTERNAL_FUNCTION(void,png_read_transform_info,(png_structrp png_ptr,
@@ -1911,6 +1919,9 @@
(png_structp png_ptr, unsigned int bpp), PNG_EMPTY);
#endif
+PNG_INTERNAL_FUNCTION(png_uint_32, png_check_keyword, (png_structrp png_ptr,
+ png_const_charp key, png_bytep new_key), PNG_EMPTY);
+
/* Maintainer: Put new private prototypes here ^ */
#include "pngdebug.h"
Modified: trunk/reactos/dll/3rdparty/libpng/pngread.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngrea…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngread.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngread.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngread.c - read a PNG file
*
* Last changed in libpng 1.6.17 [March 26, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -2838,7 +2838,6 @@
default:
png_error(png_ptr, "invalid PNG color type");
/*NOT REACHED*/
- break;
}
/* Now deal with the output processing */
Modified: trunk/reactos/dll/3rdparty/libpng/pngrio.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngrio…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngrio.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngrio.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngrio.c - functions for data input
*
* Last changed in libpng 1.6.17 [March 26, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngrtran.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngrtr…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngrtran.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngrtran.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngrtran.c - transforms the data in a row for PNG readers
*
* Last changed in libpng 1.6.19 [November 12, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngrutil.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngrut…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngrutil.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngrutil.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,8 +1,8 @@
/* pngrutil.c - utilities to read a PNG file
*
- * Last changed in libpng 1.6.19 [November 12, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Last changed in libpng 1.6.20 [December 3, 2014]
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -377,10 +377,16 @@
if (((png_ptr->options >> PNG_MAXIMUM_INFLATE_WINDOW) & 3) ==
PNG_OPTION_ON)
+ {
window_bits = 15;
+ png_ptr->zstream_start = 0; /* fixed window size */
+ }
else
+ {
window_bits = 0;
+ png_ptr->zstream_start = 1;
+ }
# else
# define window_bits 0
# endif
@@ -428,6 +434,31 @@
# undef window_bits
#endif
}
+
+#if PNG_ZLIB_VERNUM >= 0x1240
+/* Handle the start of the inflate stream if we called inflateInit2(strm,0);
+ * in this case some zlib versions skip validation of the CINFO field and, in
+ * certain circumstances, libpng may end up displaying an invalid image, in
+ * contrast to implementations that call zlib in the normal way (e.g. libpng
+ * 1.5).
+ */
+int /* PRIVATE */
+png_zlib_inflate(png_structrp png_ptr, int flush)
+{
+ if (png_ptr->zstream_start && png_ptr->zstream.avail_in > 0)
+ {
+ if ((*png_ptr->zstream.next_in >> 4) > 7)
+ {
+ png_ptr->zstream.msg = "invalid window size (libpng)";
+ return Z_DATA_ERROR;
+ }
+
+ png_ptr->zstream_start = 0;
+ }
+
+ return inflate(&png_ptr->zstream, flush);
+}
+#endif /* Zlib >= 1.2.4 */
#ifdef PNG_READ_COMPRESSED_TEXT_SUPPORTED
/* png_inflate now returns zlib error codes including Z_OK and Z_STREAM_END to
@@ -522,7 +553,7 @@
* the previous chunk of input data. Tell zlib if we have reached the
* end of the output buffer.
*/
- ret = inflate(&png_ptr->zstream, avail_out > 0 ? Z_NO_FLUSH :
+ ret = PNG_INFLATE(png_ptr, avail_out > 0 ? Z_NO_FLUSH :
(finish ? Z_FINISH : Z_SYNC_FLUSH));
} while (ret == Z_OK);
@@ -771,7 +802,7 @@
* the available output is produced; this allows reading of truncated
* streams.
*/
- ret = inflate(&png_ptr->zstream,
+ ret = PNG_INFLATE(png_ptr,
*chunk_bytes > 0 ? Z_NO_FLUSH : (finish ? Z_FINISH : Z_SYNC_FLUSH));
}
while (ret == Z_OK && (*out_size > 0 || png_ptr->zstream.avail_out
> 0));
@@ -1670,7 +1701,7 @@
++entry_start;
/* A sample depth should follow the separator, and we should be on it */
- if (entry_start > buffer + length - 2)
+ if (length < 2U || entry_start > buffer + (length - 2U))
{
png_warning(png_ptr, "malformed sPLT chunk");
return;
@@ -2174,7 +2205,7 @@
/* We need to have at least 12 bytes after the purpose string
* in order to get the parameter information.
*/
- if (endptr <= buf + 12)
+ if (endptr - buf <= 12)
{
png_chunk_benign_error(png_ptr, "invalid");
return;
@@ -4039,7 +4070,7 @@
*
* TODO: deal more elegantly with truncated IDAT lists.
*/
- ret = inflate(&png_ptr->zstream, Z_NO_FLUSH);
+ ret = PNG_INFLATE(png_ptr, Z_NO_FLUSH);
/* Take the unconsumed output back. */
if (output != NULL)
Modified: trunk/reactos/dll/3rdparty/libpng/pngset.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngset…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngset.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngset.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,7 +1,7 @@
/* pngset.c - storage of image information into info struct
*
- * Last changed in libpng 1.6.19 [November 12, 2015]
+ * Last changed in libpng 1.6.21 [January 15, 2016]
* Copyright (c) 1998-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
@@ -520,8 +520,8 @@
if (png_ptr == NULL || info_ptr == NULL)
return;
- max_palette_length = (png_ptr->color_type == PNG_COLOR_TYPE_PALETTE) ?
- (1 << png_ptr->bit_depth) : PNG_MAX_PALETTE_LENGTH;
+ max_palette_length = (info_ptr->color_type == PNG_COLOR_TYPE_PALETTE) ?
+ (1 << info_ptr->bit_depth) : PNG_MAX_PALETTE_LENGTH;
if (num_palette < 0 || num_palette > (int) max_palette_length)
{
@@ -1573,7 +1573,7 @@
{
/* Images with dimensions larger than these limits will be
* rejected by png_set_IHDR(). To accept any PNG datastream
- * regardless of dimensions, set both limits to 0x7ffffff.
+ * regardless of dimensions, set both limits to 0x7fffffff.
*/
if (png_ptr == NULL)
return;
@@ -1644,4 +1644,88 @@
png_ptr->num_palette_max = -1;
}
#endif
+
+#if defined(PNG_TEXT_SUPPORTED) || defined(PNG_pCAL_SUPPORTED) || \
+ defined(PNG_iCCP_SUPPORTED) || defined(PNG_sPLT_SUPPORTED)
+/* Check that the tEXt or zTXt keyword is valid per PNG 1.0 specification,
+ * and if invalid, correct the keyword rather than discarding the entire
+ * chunk. The PNG 1.0 specification requires keywords 1-79 characters in
+ * length, forbids leading or trailing whitespace, multiple internal spaces,
+ * and the non-break space (0x80) from ISO 8859-1. Returns keyword length.
+ *
+ * The 'new_key' buffer must be 80 characters in size (for the keyword plus a
+ * trailing '\0'). If this routine returns 0 then there was no keyword, or a
+ * valid one could not be generated, and the caller must png_error.
+ */
+png_uint_32 /* PRIVATE */
+png_check_keyword(png_structrp png_ptr, png_const_charp key, png_bytep new_key)
+{
+ png_const_charp orig_key = key;
+ png_uint_32 key_len = 0;
+ int bad_character = 0;
+ int space = 1;
+
+ png_debug(1, "in png_check_keyword");
+
+ if (key == NULL)
+ {
+ *new_key = 0;
+ return 0;
+ }
+
+ while (*key && key_len < 79)
+ {
+ png_byte ch = (png_byte)*key++;
+
+ if ((ch > 32 && ch <= 126) || (ch >= 161 /*&& ch <=
255*/))
+ *new_key++ = ch, ++key_len, space = 0;
+
+ else if (space == 0)
+ {
+ /* A space or an invalid character when one wasn't seen immediately
+ * before; output just a space.
+ */
+ *new_key++ = 32, ++key_len, space = 1;
+
+ /* If the character was not a space then it is invalid. */
+ if (ch != 32)
+ bad_character = ch;
+ }
+
+ else if (bad_character == 0)
+ bad_character = ch; /* just skip it, record the first error */
+ }
+
+ if (key_len > 0 && space != 0) /* trailing space */
+ {
+ --key_len, --new_key;
+ if (bad_character == 0)
+ bad_character = 32;
+ }
+
+ /* Terminate the keyword */
+ *new_key = 0;
+
+ if (key_len == 0)
+ return 0;
+
+#ifdef PNG_WARNINGS_SUPPORTED
+ /* Try to only output one warning per keyword: */
+ if (*key != 0) /* keyword too long */
+ png_warning(png_ptr, "keyword truncated");
+
+ else if (bad_character != 0)
+ {
+ PNG_WARNING_PARAMETERS(p)
+
+ png_warning_parameter(p, 1, orig_key);
+ png_warning_parameter_signed(p, 2, PNG_NUMBER_FORMAT_02x, bad_character);
+
+ png_formatted_warning(png_ptr, p, "keyword \"@1\": bad character
'0x@2'");
+ }
+#endif /* WARNINGS */
+
+ return key_len;
+}
+#endif /* TEXT || pCAL || iCCP || sPLT */
#endif /* READ || WRITE */
Modified: trunk/reactos/dll/3rdparty/libpng/pngstruct.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngstr…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngstruct.h [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngstruct.h [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngstruct.h - header file for PNG reference library
*
* Last changed in libpng 1.6.18 [July 23, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -263,6 +263,9 @@
/* pixel depth used for the row buffers */
png_byte transformed_pixel_depth;
/* pixel depth after read/write transforms */
+#if PNG_ZLIB_VERNUM >= 0x1240
+ png_byte zstream_start; /* at start of an input zlib stream */
+#endif /* Zlib >= 1.2.4 */
#if defined(PNG_READ_FILLER_SUPPORTED) || defined(PNG_WRITE_FILLER_SUPPORTED)
png_uint_16 filler; /* filler bytes for pixel expansion */
#endif
Modified: trunk/reactos/dll/3rdparty/libpng/pngtrans.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngtra…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngtrans.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngtrans.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngtrans.c - transforms the data in a row (used by both readers and writers)
*
* Last changed in libpng 1.6.18 [July 23, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngwio.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngwio…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngwio.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngwio.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngwio.c - functions for data output
*
* Last changed in libpng 1.6.15 [November 20, 2014]
- * Copyright (c) 1998-2014 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2014 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngwrite.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngwri…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngwrite.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngwrite.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngwrite.c - general routines to write a PNG file
*
* Last changed in libpng 1.6.19 [November 12, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngwtran.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngwtr…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngwtran.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngwtran.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -2,7 +2,7 @@
/* pngwtran.c - transforms the data in a row for PNG writers
*
* Last changed in libpng 1.6.18 [July 23, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/dll/3rdparty/libpng/pngwutil.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/3rdparty/libpng/pngwut…
==============================================================================
--- trunk/reactos/dll/3rdparty/libpng/pngwutil.c [iso-8859-1] (original)
+++ trunk/reactos/dll/3rdparty/libpng/pngwutil.c [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,8 +1,8 @@
/* pngwutil.c - utilities to write a PNG file
*
- * Last changed in libpng 1.6.19 [November 12, 2015]
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * Last changed in libpng 1.6.21 [January 15, 2016]
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -664,90 +664,6 @@
png_error(png_ptr, "error writing ancillary chunked compressed data");
}
#endif /* WRITE_COMPRESSED_TEXT */
-
-#if defined(PNG_WRITE_TEXT_SUPPORTED) || defined(PNG_WRITE_pCAL_SUPPORTED) || \
- defined(PNG_WRITE_iCCP_SUPPORTED) || defined(PNG_WRITE_sPLT_SUPPORTED)
-/* Check that the tEXt or zTXt keyword is valid per PNG 1.0 specification,
- * and if invalid, correct the keyword rather than discarding the entire
- * chunk. The PNG 1.0 specification requires keywords 1-79 characters in
- * length, forbids leading or trailing whitespace, multiple internal spaces,
- * and the non-break space (0x80) from ISO 8859-1. Returns keyword length.
- *
- * The 'new_key' buffer must be 80 characters in size (for the keyword plus a
- * trailing '\0'). If this routine returns 0 then there was no keyword, or a
- * valid one could not be generated, and the caller must png_error.
- */
-static png_uint_32
-png_check_keyword(png_structrp png_ptr, png_const_charp key, png_bytep new_key)
-{
- png_const_charp orig_key = key;
- png_uint_32 key_len = 0;
- int bad_character = 0;
- int space = 1;
-
- png_debug(1, "in png_check_keyword");
-
- if (key == NULL)
- {
- *new_key = 0;
- return 0;
- }
-
- while (*key && key_len < 79)
- {
- png_byte ch = (png_byte)*key++;
-
- if ((ch > 32 && ch <= 126) || (ch >= 161 /*&& ch <=
255*/))
- *new_key++ = ch, ++key_len, space = 0;
-
- else if (space == 0)
- {
- /* A space or an invalid character when one wasn't seen immediately
- * before; output just a space.
- */
- *new_key++ = 32, ++key_len, space = 1;
-
- /* If the character was not a space then it is invalid. */
- if (ch != 32)
- bad_character = ch;
- }
-
- else if (bad_character == 0)
- bad_character = ch; /* just skip it, record the first error */
- }
-
- if (key_len > 0 && space != 0) /* trailing space */
- {
- --key_len, --new_key;
- if (bad_character == 0)
- bad_character = 32;
- }
-
- /* Terminate the keyword */
- *new_key = 0;
-
- if (key_len == 0)
- return 0;
-
-#ifdef PNG_WARNINGS_SUPPORTED
- /* Try to only output one warning per keyword: */
- if (*key != 0) /* keyword too long */
- png_warning(png_ptr, "keyword truncated");
-
- else if (bad_character != 0)
- {
- PNG_WARNING_PARAMETERS(p)
-
- png_warning_parameter(p, 1, orig_key);
- png_warning_parameter_signed(p, 2, PNG_NUMBER_FORMAT_02x, bad_character);
-
- png_formatted_warning(png_ptr, p, "keyword \"@1\": bad character
'0x@2'");
- }
-#endif /* WARNINGS */
-
- return key_len;
-}
-#endif /* WRITE_TEXT || WRITE_pCAL || WRITE_iCCP || WRITE_sPLT */
/* Write the IHDR chunk, and update the png_struct with the necessary
* information. Note that the rest of this code depends upon this
@@ -2563,7 +2479,7 @@
if (filter_to_do == PNG_FILTER_SUB)
/* It's the only filter so no testing is needed */
{
- (void) png_setup_sub_row(png_ptr, bpp, row_bytes, mins);
+ (void) png_setup_sub_row(png_ptr, bpp, row_bytes, mins);
best_row = png_ptr->try_row;
}
@@ -2572,7 +2488,7 @@
png_size_t sum;
png_size_t lmins = mins;
- sum = png_setup_sub_row(png_ptr, bpp, row_bytes, lmins);
+ sum = png_setup_sub_row(png_ptr, bpp, row_bytes, lmins);
if (sum < mins)
{
@@ -2598,7 +2514,7 @@
png_size_t sum;
png_size_t lmins = mins;
- sum = png_setup_up_row(png_ptr, row_bytes, lmins);
+ sum = png_setup_up_row(png_ptr, row_bytes, lmins);
if (sum < mins)
{
Modified: trunk/reactos/include/reactos/libs/libpng/png.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/libs/libpn…
==============================================================================
--- trunk/reactos/include/reactos/libs/libpng/png.h [iso-8859-1] (original)
+++ trunk/reactos/include/reactos/libs/libpng/png.h [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -1,9 +1,9 @@
/* png.h - header file for PNG reference library
*
- * libpng version 1.6.19, November 12, 2015
- *
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * libpng version 1.6.21, January 15, 2016
+ *
+ * Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
@@ -12,7 +12,8 @@
* Authors and maintainers:
* libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat
* libpng versions 0.89, June 1996, through 0.96, May 1997: Andreas Dilger
- * libpng versions 0.97, January 1998, through 1.6.19, November 12, 2015: Glenn
+ * libpng versions 0.97, January 1998, through 1.6.21, January 15, 2016:
+ * Glenn Randers-Pehrson.
* See also "Contributing Authors", below.
*/
@@ -24,8 +25,8 @@
*
* This code is released under the libpng license.
*
- * libpng versions 1.0.7, July 1, 2000, through 1.6.19, November 12, 2015, are
- * Copyright (c) 2000-2002, 2004, 2006-2015 Glenn Randers-Pehrson, are
+ * libpng versions 1.0.7, July 1, 2000, through 1.6.21, January 15, 2016, are
+ * Copyright (c) 2000-2002, 2004, 2006-2016 Glenn Randers-Pehrson, are
* derived from libpng-1.0.6, and are distributed according to the same
* disclaimer and license as libpng-1.0.6 with the following individuals
* added to the list of Contributing Authors:
@@ -185,7 +186,7 @@
* ...
* 1.5.23 15 10523 15.so.15.23[.0]
* ...
- * 1.6.19 16 10619 16.so.16.19[.0]
+ * 1.6.21 16 10621 16.so.16.21[.0]
*
* Henceforth the source version will match the shared-library major
* and minor numbers; the shared-library major version number will be
@@ -213,13 +214,13 @@
* Y2K compliance in libpng:
* =========================
*
- * November 12, 2015
+ * January 15, 2016
*
* Since the PNG Development group is an ad-hoc body, we can't make
* an official declaration.
*
* This is your unofficial assurance that libpng from version 0.71 and
- * upward through 1.6.19 are Y2K compliant. It is my belief that
+ * upward through 1.6.21 are Y2K compliant. It is my belief that
* earlier versions were also Y2K compliant.
*
* Libpng only has two year fields. One is a 2-byte unsigned integer
@@ -281,9 +282,9 @@
*/
/* Version information for png.h - this should match the version in png.c */
-#define PNG_LIBPNG_VER_STRING "1.6.19"
+#define PNG_LIBPNG_VER_STRING "1.6.21"
#define PNG_HEADER_VERSION_STRING \
- " libpng version 1.6.19 - November 12, 2015\n"
+ " libpng version 1.6.21 - January 15, 2016\n"
#define PNG_LIBPNG_VER_SONUM 16
#define PNG_LIBPNG_VER_DLLNUM 16
@@ -291,7 +292,7 @@
/* These should match the first 3 components of PNG_LIBPNG_VER_STRING: */
#define PNG_LIBPNG_VER_MAJOR 1
#define PNG_LIBPNG_VER_MINOR 6
-#define PNG_LIBPNG_VER_RELEASE 19
+#define PNG_LIBPNG_VER_RELEASE 21
/* This should match the numeric part of the final component of
* PNG_LIBPNG_VER_STRING, omitting any leading zero:
@@ -322,7 +323,7 @@
* version 1.0.0 was mis-numbered 100 instead of 10000). From
* version 1.0.1 it's xxyyzz, where x=major, y=minor, z=release
*/
-#define PNG_LIBPNG_VER 10619 /* 1.6.19 */
+#define PNG_LIBPNG_VER 10621 /* 1.6.21 */
/* Library configuration: these options cannot be changed after
* the library has been built.
@@ -432,7 +433,7 @@
/* This triggers a compiler error in png.c, if png.c and png.h
* do not agree upon the version number.
*/
-typedef char* png_libpng_version_1_6_19;
+typedef char* png_libpng_version_1_6_21;
/* Basic control structions. Read libpng-manual.txt or libpng.3 for more info.
*
Modified: trunk/reactos/include/reactos/libs/libpng/pngconf.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/libs/libpn…
==============================================================================
--- trunk/reactos/include/reactos/libs/libpng/pngconf.h [iso-8859-1] (original)
+++ trunk/reactos/include/reactos/libs/libpng/pngconf.h [iso-8859-1] Wed Apr 20 09:00:52
2016
@@ -1,9 +1,9 @@
/* pngconf.h - machine configurable file for libpng
*
- * libpng version 1.6.19, July 23, 2015
- *
- * Copyright (c) 1998-2015 Glenn Randers-Pehrson
+ * libpng version 1.6.21, January 15, 2016
+ *
+ * Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
* (Version 0.88 Copyright (c) 1995, 1996 Guy Eric Schalnat, Group 42, Inc.)
*
Modified: trunk/reactos/include/reactos/libs/libpng/pnglibconf.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/libs/libpn…
==============================================================================
--- trunk/reactos/include/reactos/libs/libpng/pnglibconf.h [iso-8859-1] (original)
+++ trunk/reactos/include/reactos/libs/libpng/pnglibconf.h [iso-8859-1] Wed Apr 20
09:00:52 2016
@@ -1,8 +1,8 @@
-/* libpng 1.6.19 STANDARD API DEFINITION */
+/* libpng 1.6.21 STANDARD API DEFINITION */
/* pnglibconf.h - library build configuration */
-/* Libpng version 1.6.19 - November 12, 2015 */
+/* Libpng version 1.6.21 - January 15, 2016 */
/* Copyright (c) 1998-2015 Glenn Randers-Pehrson */
Modified: trunk/reactos/media/doc/3rd Party Files.txt
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/3rd%20Party%20Fi…
==============================================================================
--- trunk/reactos/media/doc/3rd Party Files.txt [iso-8859-1] (original)
+++ trunk/reactos/media/doc/3rd Party Files.txt [iso-8859-1] Wed Apr 20 09:00:52 2016
@@ -87,5 +87,5 @@
Website:
https://tls.mbed.org/
Title: libpng
-Used Version: 1.6.19
+Used Version: 1.6.21
Website:
http://libpng.sourceforge.net/