From 12c3c2e136ea077eecdb1bb1ff4d92684e0f5d3b Mon Sep 17 00:00:00 2001 From: Glenn Randers-Pehrson Date: Fri, 24 Jun 2016 21:36:29 -0500 Subject: [PATCH] [libpng17] Sync pngvalid.c with libpng16; update CHANGES and ANNOUNCE --- ANNOUNCE | 6 ++++-- CHANGES | 5 ++++- contrib/libtests/pngvalid.c | 4 ++-- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index cab1e5055..f4ab99664 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,5 +1,5 @@ -Libpng 1.7.0beta82 - June 23, 2016 +Libpng 1.7.0beta82 - June 24, 2016 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. @@ -1290,7 +1290,7 @@ Version 1.7.0beta80 [May 6, 2016] unreachable code in pz_default_settings and eliminated a spurious warning in pngcp for small files. -Version 1.7.0beta81 [June 23, 2016] +Version 1.7.0beta81 [June 24, 2016] Check for CLOCK_PROCESS_CPUTIME_ID when building /contrib/libtests/timepng. Otherwise it does not build on platforms that don't supply clock_gettime(). Add check for clock_gettime() in Makefile.am and configure.ac @@ -1379,6 +1379,8 @@ Version 1.7.0beta81 [June 23, 2016] previously were swapped. Avoid potential overflow of the PNG_IMAGE_SIZE macro. This macro is not used within libpng, but is used in some of the examples. + +Version 1.7.0beta82 [June 24, 2016] Put the SKIP definition in the correct place. It needs to come after the png.h include (see all the other .c files in contrib/libtests) because it depends on PNG_LIBPNG_VER. diff --git a/CHANGES b/CHANGES index b746a5347..0fb2cdb96 100644 --- a/CHANGES +++ b/CHANGES @@ -5590,7 +5590,7 @@ Version 1.7.0beta80 [May 6, 2016] unreachable code in pz_default_settings and eliminated a spurious warning in pngcp for small files. -Version 1.7.0beta81 [June 23, 2016] +Version 1.7.0beta81 [June 24, 2016] Check for CLOCK_PROCESS_CPUTIME_ID when building /contrib/libtests/timepng. Otherwise it does not build on platforms that don't supply clock_gettime(). Add check for clock_gettime() in Makefile.am and configure.ac @@ -5679,10 +5679,13 @@ Version 1.7.0beta81 [June 23, 2016] previously were swapped. Avoid potential overflow of the PNG_IMAGE_SIZE macro. This macro is not used within libpng, but is used in some of the examples. + +Version 1.7.0beta82 [June 24, 2016] Put the SKIP definition in the correct place. It needs to come after the png.h include (see all the other .c files in contrib/libtests) because it depends on PNG_LIBPNG_VER. + Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit https://lists.sourceforge.net/lists/listinfo/png-mng-implement diff --git a/contrib/libtests/pngvalid.c b/contrib/libtests/pngvalid.c index b21390ba2..13b0b8df2 100644 --- a/contrib/libtests/pngvalid.c +++ b/contrib/libtests/pngvalid.c @@ -1,7 +1,7 @@ /* pngvalid.c - validate libpng by constructing then reading png files. * - * Last changed in libpng 1.6.23 [(PENDING RELEASE)] + * Last changed in libpng 1.6.24 [(PENDING RELEASE)] * Copyright (c) 2014-2016 Glenn Randers-Pehrson * Written by John Cunningham Bowler * @@ -1589,7 +1589,7 @@ store_read_chunk(png_store *ps, png_bytep pb, const png_size_t max, { if (chunkpos < chunklen-4U) { - uInt avail = -1; + uInt avail = (uInt)-1; if (avail > (IDAT_len-4U) - IDAT_pos) avail = (uInt)/*SAFE*/((IDAT_len-4U) - IDAT_pos);