[libpng17] Fixed another Coverity defect, NULL dereference "ps" in pngwutil.c

This commit is contained in:
Glenn Randers-Pehrson 2016-01-08 18:59:36 -06:00
parent 27e11dc8cf
commit 09a1afbb3d
3 changed files with 6 additions and 4 deletions

View File

@ -1,5 +1,5 @@
Libpng 1.7.0beta77 - January 7, 2016
Libpng 1.7.0beta77 - January 9, 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.
@ -1172,7 +1172,8 @@ Version 1.7.0beta76 [January 7, 2016]
Fixed new Coverity defect, potential NULL dereference of "ps" in pngwutil.c
Added temporary workaround for Coverity "Dead code" defect.
Version 1.7.0beta77 [January 7, 2016]
Version 1.7.0beta77 [January 9, 2016]
Fixed new Coverity defect, another NULL dereference of "ps" in pngwutil.c
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
(subscription required; visit

View File

@ -5471,7 +5471,8 @@ Version 1.7.0beta76 [January 7, 2016]
Fixed new Coverity defect, potential NULL dereference of "ps" in pngwutil.c
Added temporary workaround for Coverity "Dead code" defect.
Version 1.7.0beta77 [January 7, 2016]
Version 1.7.0beta77 [January 9, 2016]
Fixed new Coverity defect, another NULL dereference of "ps" in pngwutil.c
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
(subscription required; visit

View File

@ -2272,7 +2272,7 @@ png_start_IDAT(png_structrp png_ptr)
}
# endif /* WRITE_FILTER */
if (ps->zlib_strategy == (-1)/*unset*/)
if (ps && ps->zlib_strategy == (-1)/*unset*/)
{
# ifdef PNG_WRITE_FILTER_SUPPORTED
if (ps->filter_mask != PNG_FILTER_NONE)