[libpng15] Change info_ptr->unknown_chunks_num to type png_uint_32

and test against INT_MAX instead of UINT_MAX in pngset.c
This commit is contained in:
Glenn Randers-Pehrson 2013-01-17 10:52:48 -06:00
parent 5b9fe98c5f
commit 77a817bfc2
4 changed files with 16 additions and 10 deletions

View File

@ -1,5 +1,5 @@
Libpng 1.5.14rc01 - January 17, 2013
Libpng 1.5.14rc02 - January 17, 2013
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.
@ -9,20 +9,20 @@ Files available for download:
Source files with LF line endings (for Unix/Linux) and with a
"configure" script
1.5.14rc01.tar.xz (LZMA-compressed, recommended)
1.5.14rc01.tar.gz
1.5.14rc01.tar.bz2
1.5.14rc02.tar.xz (LZMA-compressed, recommended)
1.5.14rc02.tar.gz
1.5.14rc02.tar.bz2
Source files with CRLF line endings (for Windows), without the
"configure" script
lp1514r01.7z (LZMA-compressed, recommended)
lp1514r01.zip
lp1514r02.7z (LZMA-compressed, recommended)
lp1514r02.zip
Other information:
1.5.14rc01-README.txt
1.5.14rc01-LICENSE.txt
1.5.14rc02-README.txt
1.5.14rc02-LICENSE.txt
Changes since the last public release (1.5.13):
@ -80,6 +80,9 @@ Version 1.5.14beta08 [January 10, 2013]
Version 1.5.14rc01 [January 17, 2013]
No changes.
Version 1.5.14rc02 [January 17, 2013]
Change info_ptr->unknown_chunks_num to type png_uint_32
===========================================================================
NOTICE November 17, 2012:
The location of the git repository at SourceForge has changed.

View File

@ -3973,6 +3973,9 @@ Version 1.5.14beta08 [January 10, 2013]
Version 1.5.14rc01 [January 17, 2013]
No changes.
Version 1.5.14rc02 [January 17, 2013]
Change info_ptr->unknown_chunks_num to type png_uint_32
===========================================================================
NOTICE November 17, 2012:
The location of the git repository at SourceForge has changed.

View File

@ -228,7 +228,7 @@ defined(PNG_READ_BACKGROUND_SUPPORTED)
defined(PNG_HANDLE_AS_UNKNOWN_SUPPORTED)
/* Storage for unknown chunks that the library doesn't recognize. */
png_unknown_chunkp unknown_chunks;
int unknown_chunks_num;
png_uint_32 unknown_chunks_num;
#endif
#ifdef PNG_iCCP_SUPPORTED

View File

@ -1040,7 +1040,7 @@ png_set_unknown_chunks(png_structp png_ptr,
return;
if (num_unknowns < 0 ||
num_unknowns >= UINT_MAX-info_ptr->unknown_chunks_num ||
num_unknowns >= INT_MAX-info_ptr->unknown_chunks_num ||
num_unknowns >= PNG_SIZE_MAX/png_sizeof(png_unknown_chunk)
- info_ptr->unknown_chunks_num)
np=NULL;