iliaa Tue Jun 3 20:22:31 2003 EDT Modified files: (Branch: PHP_4_3) /php4 NEWS /php4/ext/gd gd.c /php4/ext/gd/libgd gd.c Log: MFH Index: php4/NEWS diff -u php4/NEWS:1.1247.2.236 php4/NEWS:1.1247.2.237 --- php4/NEWS:1.1247.2.236 Tue Jun 3 19:57:58 2003 +++ php4/NEWS Tue Jun 3 20:22:30 2003 @@ -17,7 +17,7 @@ - Added long options into CLI & CGI (e.g. --version). (Marcus) - Fixed ext/yaz to not log unless yaz.log_file is set. (Adam Dickmeiss) - Fixed ext/exif to honor "magic_quotes_runtime" php.ini option. (Marcus) -- Synchronized bundled GD library with GD 2.0.14. (Ilia) +- Synchronized bundled GD library with GD 2.0.15. (Ilia) - Added integer overflow checks to bundled GD library. (Ilia) - Fixed bug #23913 (make rename() work across partitions on *nix). (Ilia) - Fixed bug #23912 (Invalid CSS in phpinfo() output). (Ilia) Index: php4/ext/gd/gd.c diff -u php4/ext/gd/gd.c:1.221.2.28 php4/ext/gd/gd.c:1.221.2.29 --- php4/ext/gd/gd.c:1.221.2.28 Tue Jun 3 19:55:14 2003 +++ php4/ext/gd/gd.c Tue Jun 3 20:22:30 2003 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: gd.c,v 1.221.2.28 2003/06/03 23:55:14 iliaa Exp $ */ +/* $Id: gd.c,v 1.221.2.29 2003/06/04 00:22:30 iliaa Exp $ */ /* gd 1.2 is copyright 1994, 1995, Quest Protein Database Center, Cold Spring Harbor Labs. */ @@ -386,7 +386,7 @@ /* }}} */ #if HAVE_GD_BUNDLED -#define PHP_GD_VERSION_STRING "bundled (2.0.14 compatible)" +#define PHP_GD_VERSION_STRING "bundled (2.0.15 compatible)" #elif HAVE_LIBGD20 #define PHP_GD_VERSION_STRING "2.0 or higher" #elif HAVE_GDIMAGECOLORRESOLVE Index: php4/ext/gd/libgd/gd.c diff -u php4/ext/gd/libgd/gd.c:1.24.2.10 php4/ext/gd/libgd/gd.c:1.24.2.11 --- php4/ext/gd/libgd/gd.c:1.24.2.10 Tue Jun 3 19:55:15 2003 +++ php4/ext/gd/libgd/gd.c Tue Jun 3 20:22:30 2003 @@ -873,11 +873,6 @@ float p_dist, p_alpha; unsigned char opacity; - /* 2.0.13: bounds check! AA_opacity is just as capable of overflowing as the main pixel array. Arne Jorgensen. */ - if (!gdImageBoundsSafeMacro(im, px, py)) { - return; - } - /* * Find the perpendicular distance from point C (px, py) to the line * segment AB that is being drawn. (Adapted from an algorithm from the @@ -891,6 +886,15 @@ int Bx_Cx = im->AAL_x2 - px; int By_Cy = im->AAL_y2 - py; + + /* 2.0.13: bounds check! AA_opacity is just as capable of + * overflowing as the main pixel array. Arne Jorgensen. + * 2.0.14: typo fixed. 2.0.15: moved down below declarations + * to satisfy non-C++ compilers. + */ + if (!gdImageBoundsSafeMacro(im, px, py)) { + return; + } /* Get the squares of the lengths of the segemnts AC and BC. */ LAC_2 = (Ax_Cx * Ax_Cx) + (Ay_Cy * Ay_Cy);
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php