diff options
author | Glenn Randers-Pehrson <glennrp at users.sourceforge.net> | 2015-01-31 13:54:10 -0600 |
---|---|---|
committer | Glenn Randers-Pehrson <glennrp at users.sourceforge.net> | 2015-01-31 13:54:10 -0600 |
commit | e0e239ada02296dff3cb176b2dbe417ecd29302c (patch) | |
tree | b58d37466a0254c37d3404c53180714d1b8499b1 /pngwrite.c | |
parent | a4d40f32ddfb0de467e1f2be5b55e42723ca9d33 (diff) | |
download | libpng-e0e239ada02296dff3cb176b2dbe417ecd29302c.tar.gz |
[libpng12] Quieted some harmless warnings from Coverity-scan.
Diffstat (limited to 'pngwrite.c')
-rw-r--r-- | pngwrite.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/pngwrite.c b/pngwrite.c index 894a9843d..251ac5525 100644 --- a/pngwrite.c +++ b/pngwrite.c @@ -1,8 +1,8 @@ /* pngwrite.c - general routines to write a PNG file * - * Last changed in libpng 1.2.52 [November 20, 2014] - * Copyright (c) 1998-2014 Glenn Randers-Pehrson + * Last changed in libpng 1.2.53 [%RDATE%] + * 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.) * @@ -1201,14 +1201,13 @@ png_set_filter(png_structp png_ptr, int method, int filters) { switch (filters & (PNG_ALL_FILTERS | 0x07)) { + case PNG_FILTER_VALUE_NONE: + png_ptr->do_filter = PNG_FILTER_NONE; break; #ifdef PNG_WRITE_FILTER_SUPPORTED case 5: case 6: case 7: png_warning(png_ptr, "Unknown row filter for method 0"); -#endif /* PNG_WRITE_FILTER_SUPPORTED */ - case PNG_FILTER_VALUE_NONE: - png_ptr->do_filter = PNG_FILTER_NONE; break; -#ifdef PNG_WRITE_FILTER_SUPPORTED + break; case PNG_FILTER_VALUE_SUB: png_ptr->do_filter = PNG_FILTER_SUB; break; case PNG_FILTER_VALUE_UP: @@ -1220,6 +1219,7 @@ png_set_filter(png_structp png_ptr, int method, int filters) default: png_ptr->do_filter = (png_byte)filters; break; #else default: png_warning(png_ptr, "Unknown row filter for method 0"); + break; #endif /* PNG_WRITE_FILTER_SUPPORTED */ } |