diff --git a/ANNOUNCE b/ANNOUNCE index 30d545ff7478753ab878c1b1b1bff47b3603dd73..67d5dc57f44c32117661876030829aeeef6a6bde 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,4 +1,4 @@ -Libpng 1.6.15beta07 - November 6, 2014 +Libpng 1.6.15beta07 - November 7, 2014 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. @@ -66,7 +66,11 @@ Version 1.6.15beta06 [November 6, 2014] in the manual, example.c, pngtest.c, and applications in the contrib directory. It was incorrect advice. -Version 1.6.15beta07 [November 6, 2014] +Version 1.6.15beta07 [November 7, 2014] + Removed #ifdef PNG_16BIT_SUPPORTED/#endif around png_product2(); it is + needed by png_reciprocal2(). + Added #ifdef PNG_16BIT_SUPPORTED/#endif around png_log16bit() and + png_do_swap(). Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/CHANGES b/CHANGES index 896f772997be5733a1d411e75d8d9a87e061e895..eb16d3e5739aa1745f2cf06ba9a252f6bc59ced7 100644 --- a/CHANGES +++ b/CHANGES @@ -5074,7 +5074,11 @@ Version 1.6.15beta06 [November 6, 2014] in the manual, example.c, pngtest.c, and applications in the contrib directory. It was incorrect advice. -Version 1.6.15beta07 [November 6, 2014] +Version 1.6.15beta07 [November 7, 2014] + Removed #ifdef PNG_16BIT_SUPPORTED/#endif around png_product2(); it is + needed by png_reciprocal2(). + Added #ifdef PNG_16BIT_SUPPORTED/#endif around png_log16bit() and + png_do_swap(). Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/png.c b/png.c index 1ec445bb876018a527c496ea1d45c6dd08b74f7a..ad7d4d161bf1133e3eb22507a2a3b187fed945f6 100644 --- a/png.c +++ b/png.c @@ -769,13 +769,13 @@ png_get_copyright(png_const_structrp png_ptr) #else # ifdef __STDC__ return PNG_STRING_NEWLINE \ - "libpng version 1.6.15beta07 - November 6, 2014" PNG_STRING_NEWLINE \ + "libpng version 1.6.15beta07 - November 7, 2014" PNG_STRING_NEWLINE \ "Copyright (c) 1998-2014 Glenn Randers-Pehrson" PNG_STRING_NEWLINE \ "Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \ "Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc." \ PNG_STRING_NEWLINE; # else - return "libpng version 1.6.15beta07 - November 6, 2014\ + return "libpng version 1.6.15beta07 - November 7, 2014\ Copyright (c) 1998-2014 Glenn Randers-Pehrson\ Copyright (c) 1996-1997 Andreas Dilger\ Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc."; @@ -3372,7 +3372,7 @@ png_gamma_significant(png_fixed_point gamma_val) #endif #ifdef PNG_READ_GAMMA_SUPPORTED -# ifdef PNG_16BIT_SUPPORTED +#if defined(PNG_16BIT_SUPPORTED) || !defined(PNG_FLOATING_ARITHMETIC_SUPPORTED) /* A local convenience routine. */ static png_fixed_point png_product2(png_fixed_point a, png_fixed_point b) @@ -3394,7 +3394,7 @@ png_product2(png_fixed_point a, png_fixed_point b) return 0; /* overflow */ } -# endif /* 16BIT */ +#endif /* PNG_16BIT_SUPPORTED) || !PNG_FLOATING_ARITHMETIC_SUPPORTED */ /* The inverse of the above. */ png_fixed_point @@ -3546,6 +3546,7 @@ png_log8bit(unsigned int x) * Zero (257): 0 * End (258): 23499 */ +#ifdef PNG_16BIT_SUPPORTED static png_int_32 png_log16bit(png_uint_32 x) { @@ -3596,6 +3597,7 @@ png_log16bit(png_uint_32 x) /* Safe, because the result can't have more than 20 bits: */ return (png_int_32)((lg2 + 2048) >> 12); } +#endif /* 16BIT */ /* The 'exp()' case must invert the above, taking a 20-bit fixed point * logarithmic value and returning a 16 or 8-bit number as appropriate. In diff --git a/pngrtran.c b/pngrtran.c index 8d7904cb9d2816f2bdd189f344641ed2b113b5ea..d7a4f1ba7febf1cf0f1308abe8b4c3ea1ac908e1 100644 --- a/pngrtran.c +++ b/pngrtran.c @@ -4962,7 +4962,7 @@ png_do_read_transformations(png_structrp png_ptr, png_row_infop row_info) #ifdef PNG_READ_USER_TRANSFORM_SUPPORTED if ((png_ptr->transformations & PNG_USER_TRANSFORM) != 0) - { + { if (png_ptr->read_user_transform_fn != NULL) (*(png_ptr->read_user_transform_fn)) /* User read transform function */ (png_ptr, /* png_ptr */ diff --git a/pngwtran.c b/pngwtran.c index dcb0160be5b78e7465c2f6137cea9f87cea2a1be..e905b3f4a2ac4213fec5bc36f893cedd5834d486 100644 --- a/pngwtran.c +++ b/pngwtran.c @@ -538,8 +538,10 @@ png_do_write_transformations(png_structrp png_ptr, png_row_infop row_info) #endif #ifdef PNG_WRITE_SWAP_SUPPORTED +# ifdef PNG_16BIT_SUPPORTED if ((png_ptr->transformations & PNG_SWAP_BYTES) != 0) png_do_swap(row_info, png_ptr->row_buf + 1); +# endif #endif #ifdef PNG_WRITE_SHIFT_SUPPORTED