[libpng16] Worked around a false-positive Coverity issue in pngvalid.c.

This commit is contained in:
Glenn Randers-Pehrson 2016-01-13 09:50:41 -06:00
parent 253326c52d
commit 780079e771
3 changed files with 27 additions and 10 deletions

View File

@ -1,4 +1,4 @@
Libpng 1.6.21rc02 - January 7, 2016
Libpng 1.6.21rc03 - January 13, 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.
@ -8,20 +8,20 @@ Files available for download:
Source files with LF line endings (for Unix/Linux) and with a
"configure" script
1.6.21rc02.tar.xz (LZMA-compressed, recommended)
1.6.21rc02.tar.gz
1.6.21rc03.tar.xz (LZMA-compressed, recommended)
1.6.21rc03.tar.gz
Source files with CRLF line endings (for Windows), without the
"configure" script
/scratch/glennrp/Libpng16/lp1621r02.7z (LZMA-compressed, recommended)
/scratch/glennrp/Libpng16/lp1621r02.zip
/scratch/glennrp/Libpng16/lp1621r03.7z (LZMA-compressed, recommended)
/scratch/glennrp/Libpng16/lp1621r03.zip
Other information:
1.6.21rc02-README.txt
1.6.21rc02-LICENSE.txt
libpng-1.6.21rc02-*.asc (armored detached GPG signatures)
1.6.21rc03-README.txt
1.6.21rc03-LICENSE.txt
libpng-1.6.21rc03-*.asc (armored detached GPG signatures)
Changes since the last public release (1.6.20):
@ -60,6 +60,9 @@ Version 1.6.21rc02 [January 7, 2016]
Marked 'limit' UNUSED in transform_range_check(). This only affects
release builds.
Version 1.6.21rc03 [January 13, 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
https://lists.sourceforge.net/lists/listinfo/png-mng-implement

View File

@ -5481,6 +5481,9 @@ Version 1.6.21rc02 [January 7, 2016]
Marked 'limit' UNUSED in transform_range_check(). This only affects
release builds.
Version 1.6.21rc03 [January 13, 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
https://lists.sourceforge.net/lists/listinfo/png-mng-implement

View File

@ -309,8 +309,13 @@ static void r16(png_uint_16p p16, size_t count)
}
}
#define R16(this)\
#ifdef __COVERITY__
# define R16(this)\
r16(&(this), (sizeof (this))/2U/*(sizeof (png_uint_16))*/)
#else
# define R16(this)\
r16(&(this), (sizeof (this))/(sizeof (png_uint_16)))
#endif
#if defined PNG_READ_RGB_TO_GRAY_SUPPORTED ||\
defined PNG_READ_FILLER_SUPPORTED
@ -326,8 +331,14 @@ static void r32(png_uint_32p p32, size_t count)
}
}
#define R32(this)\
#ifdef __COVERITY__
# define R32(this)\
r32(&(this), (sizeof (this))/4U/*(sizeof (png_uint_32))*/)
#else
# define R32(this)\
r32(&(this), (sizeof (this))/(sizeof (png_uint_32)))
#endif
#endif /* READ_FILLER || READ_RGB_TO_GRAY */
#endif /* READ || WRITE_tRNS || WRITE_FILTER */