From 9b8ddff5b7e30f8cbdd97bf5b9c96c56aa87943f Mon Sep 17 00:00:00 2001 From: Glenn Randers-Pehrson Date: Mon, 3 May 2010 15:19:11 -0500 Subject: [PATCH] [master] Added a typecast in pngrutil.c to stifle compiler warning in the calculation of the png_ptr->rowbuf pointer into png_ptr->big_row_buf. --- ANNOUNCE | 2 ++ CHANGES | 2 ++ pngrutil.c | 3 ++- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ANNOUNCE b/ANNOUNCE index e5ea10807..516018dfa 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -62,6 +62,8 @@ version 1.4.2rc05 [April 29, 2010] version 1.4.2rc06 [May 3, 2010] Moved declarations of umsg[] inside the proper #ifdef blocks in pngrutil.c + Added a typecast in pngrutil.c to stifle compiler warning in the calculation + of the png_ptr->rowbuf pointer into png_ptr->big_row_buf. Send comments/corrections/commendations to glennrp at users.sourceforge.net or to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/CHANGES b/CHANGES index bbc547a1a..18bdf636f 100644 --- a/CHANGES +++ b/CHANGES @@ -2573,6 +2573,8 @@ version 1.4.2rc05 [April 29, 2010] version 1.4.2rc06 [May 3, 2010] Moved declarations of umsg[] inside the proper #ifdef blocks in pngrutil.c + Added a typecast in pngrutil.c to stifle compiler warning in the calculation + of the png_ptr->rowbuf pointer into png_ptr->big_row_buf. Send comments/corrections/commendations to glennrp at users.sourceforge.net or to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/pngrutil.c b/pngrutil.c index 2fc3ac289..1898f30d0 100644 --- a/pngrutil.c +++ b/pngrutil.c @@ -3326,7 +3326,8 @@ defined(PNG_USER_TRANSFORM_PTR_SUPPORTED) * of padding before and after row_buf. */ png_ptr->row_buf = png_ptr->big_row_buf + 32 - - (((png_alloc_size_t)&(png_ptr->big_row_buf[0]) + 15) % 16); + - (((png_alloc_size_t)&(png_ptr->big_row_buf[0]) + + (png_alloc_size_t)15) % 16); png_ptr->old_big_row_buf_size = row_bytes + 48; #else /* Use 32 bytes of padding before and 16 bytes after row_buf. */