From 23b9a2fda00bd3fbfbb59a8062f342fbf6dd6719 Mon Sep 17 00:00:00 2001 From: Glenn Randers-Pehrson Date: Sun, 14 Feb 2010 06:48:09 -0600 Subject: [PATCH] [master] Fixed incorrect typecast of png_get_user_malloc_max() in pngget.c --- ANNOUNCE | 21 ++++++++++++--------- CHANGES | 7 +++++-- pngget.c | 6 +++--- 3 files changed, 20 insertions(+), 14 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index f6b033590..a02e64ad2 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,5 +1,5 @@ -Libpng 1.4.1beta11 - February 13, 2010 +Libpng 1.4.1beta12 - February 14, 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. @@ -9,20 +9,20 @@ Files available for download: Source files with LF line endings (for Unix/Linux) and with a "configure" script - 1.4.1beta11.tar.xz (LZMA-compressed, recommended) - 1.4.1beta11.tar.gz - 1.4.1beta11.tar.bz2 + 1.4.1beta12.tar.xz (LZMA-compressed, recommended) + 1.4.1beta12.tar.gz + 1.4.1beta12.tar.bz2 Source files with CRLF line endings (for Windows), without the "configure" script - lp141b11.zip - lp141b11.7z + lp141b12.zip + lp141b12.7z Other information: - 1.4.1beta11-README.txt - 1.4.1beta11-LICENSE.txt + 1.4.1beta12-README.txt + 1.4.1beta12-LICENSE.txt Changes since the last public release (1.4.0): @@ -76,12 +76,15 @@ version 1.4.1beta10 [February 9, 2010] Return allocated "old_buffer" in png_push_save_buffer() before calling png_error(), to avoid a potential memory leak. -version 1.4.1beta11 [February 13, 2010] +version 1.4.1beta11 [February 12, 2010] Removed the cbuilder5 project, which has not been updated to 1.4.0. Removed unused "buffer_size" variable from png_decompress_chunk(). Relocated misplaced closing curley bracket in png_decompress_chunk(). Complete rewrite of two-pass png_decompress_chunk() by John Bowler. +version 1.4.1beta12 [February 14, 2010] + Fixed incorrect typecast of png_get_user_malloc_max() in pngget.c + Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/CHANGES b/CHANGES index 35f9bda78..f41896971 100644 --- a/CHANGES +++ b/CHANGES @@ -2509,13 +2509,16 @@ version 1.4.1beta10 [February 9, 2010] Return allocated "old_buffer" in png_push_save_buffer() before calling png_error(), to avoid a potential memory leak. -version 1.4.1beta11 [February 13, 2010] +version 1.4.1beta11 [February 12, 2010] Relocated misplaced closing curley bracket in png_decompress_chunk(). Removed unused "buffer_size" variable from png_decompress_chunk(). Removed the cbuilder5 project, which has not been updated to 1.4.0. Complete rewrite of two-pass png_decompress_chunk() by John Bowler. -version 1.4.1rc02 [February 13, 2010] +version 1.4.1beta12 [February 14, 2010] + Fixed incorrect typecast of png_get_user_malloc_max() in pngget.c + +version 1.4.1rc02 [February 14, 2010] Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/pngget.c b/pngget.c index ca73e7f82..4cb1442d5 100644 --- a/pngget.c +++ b/pngget.c @@ -1,7 +1,7 @@ /* pngget.c - retrieval of values from info struct * - * Last changed in libpng 1.4.1 [February 13, 2010] + * Last changed in libpng 1.4.1 [February 14, 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.) @@ -899,11 +899,11 @@ png_get_chunk_cache_max (png_structp png_ptr) return (png_ptr? png_ptr->user_chunk_cache_max : 0); } /* This function was added to libpng 1.4.1 */ -png_uint_32 PNGAPI +png_alloc_size_t PNGAPI png_get_chunk_malloc_max (png_structp png_ptr) { return (png_ptr? - (png_uint_32)png_ptr->user_chunk_malloc_max : 0); + png_ptr->user_chunk_malloc_max : 0); } #endif /* ?PNG_SET_USER_LIMITS_SUPPORTED */