From cf2fd3b6ca4ca0758f986c38415575517a8e56bd Mon Sep 17 00:00:00 2001 From: Glenn Randers-Pehrson Date: Wed, 28 Apr 2010 21:25:18 -0500 Subject: [PATCH] [devel] Corrected protection of png_get_user_transform_ptr. The API declaration in png.h is removed if both READ and WRITE USER_TRANSFORM are turned off but was left defined in pngtrans.c --- ANNOUNCE | 7 +++++-- CHANGES | 5 ++++- pngtrans.c | 5 +++-- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 883c9e5f5..293f396cb 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,5 +1,5 @@ -Libpng 1.5.0beta23 - April 28, 2010 +Libpng 1.5.0beta23 - April 29, 2010 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. @@ -202,13 +202,16 @@ version 1.5.0beta22 [April 28, 2010] Improved the options.awk script; added an "everything off" option. Revised contrib/pngminim to use the "everything off" option in pngusr.dfa. -version 1.5.0beta23 [April 28, 2010] +version 1.5.0beta23 [April 29, 2010] Corrected PNG_REMOVED macro to take five arguments. The macro was documented with two arguments (name,ordinal), however the symbol checking .dfn files assumed five arguments. The five argument form seems more useful so it is changed to that. Corrected PNG_UNKNOWN_CHUNKS_SUPPORTED to PNG_HANDLE_AS_UNKNOWN_SUPPORTED in gregbook/readpng2.c + Corrected protection of png_get_user_transform_ptr. The API declaration in + png.h is removed if both READ and WRITE USER_TRANSFORM are turned off + but was left defined in pngtrans.c Send comments/corrections/commendations to png-mng-implement at lists.sf.net: (subscription required; visit diff --git a/CHANGES b/CHANGES index 3bb5a1263..090e4fbd8 100644 --- a/CHANGES +++ b/CHANGES @@ -2684,13 +2684,16 @@ version 1.5.0beta22 [April 28, 2010] Improved the options.awk script; added an "everything off" option. Revised contrib/pngminim to use the "everything off" option in pngusr.dfa. -version 1.5.0beta23 [April 28, 2010] +version 1.5.0beta23 [April 29, 2010] Corrected PNG_REMOVED macro to take five arguments. The macro was documented with two arguments (name,ordinal), however the symbol checking .dfn files assumed five arguments. The five argument form seems more useful so it is changed to that. Corrected PNG_UNKNOWN_CHUNKS_SUPPORTED to PNG_HANDLE_AS_UNKNOWN_SUPPORTED in gregbook/readpng2.c + Corrected protection of png_get_user_transform_ptr. The API declaration in + png.h is removed if both READ and WRITE USER_TRANSFORM are turned off + but was left defined in pngtrans.c Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/pngtrans.c b/pngtrans.c index 6d9b5dc1b..187c894ee 100644 --- a/pngtrans.c +++ b/pngtrans.c @@ -1,7 +1,7 @@ /* pngtrans.c - transforms the data in a row (used by both readers and writers) * - * Last changed in libpng 1.5.0 [April 28, 2010] + * Last changed in libpng 1.5.0 [April 29, 2010] * Copyright (c) 1998-2010 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.) @@ -654,7 +654,6 @@ png_set_user_transform_info(png_structp png_ptr, png_voidp "This version of libpng does not support user transform info"); #endif } -#endif /* This function returns a pointer to the user_transform_ptr associated with * the user transform functions. The application should free any memory @@ -672,4 +671,6 @@ png_get_user_transform_ptr(png_structp png_ptr) return (NULL); #endif } +#endif /* PNG_READ_USER_TRANSFORM_SUPPORTED || + PNG_WRITE_USER_TRANSFORM_SUPPORTED */ #endif /* PNG_READ_SUPPORTED || PNG_WRITE_SUPPORTED */