pajoye Mon May 8 11:56:15 2006 UTC Added files: (Branch: PHP_5_1) /php-src/ext/gd/tests bug37360.phpt bug37360.gif
Modified files: /php-src/ext/gd/libgd gd_gif_in.c /php-src NEWS Log: - MFH: #37360, bad gif size http://cvs.php.net/viewcvs.cgi/php-src/ext/gd/libgd/gd_gif_in.c?r1=1.5.4.3&r2=1.5.4.4&diff_format=u Index: php-src/ext/gd/libgd/gd_gif_in.c diff -u php-src/ext/gd/libgd/gd_gif_in.c:1.5.4.3 php-src/ext/gd/libgd/gd_gif_in.c:1.5.4.4 --- php-src/ext/gd/libgd/gd_gif_in.c:1.5.4.3 Sun May 7 17:14:36 2006 +++ php-src/ext/gd/libgd/gd_gif_in.c Mon May 8 11:56:14 2006 @@ -147,6 +147,9 @@ Background = buf[5]; AspectRatio = buf[6]; + imw = LM_to_uint(buf[0],buf[1]); + imh = LM_to_uint(buf[2],buf[3]); + if (BitSet(buf[4], LOCALCOLORMAP)) { /* Global Colormap */ if (ReadColorMap(fd, BitPixel, ColorMap)) { return 0; @@ -182,8 +185,6 @@ bitPixel = 1<<((buf[8]&0x07)+1); - imw = LM_to_uint(buf[4],buf[5]); - imh = LM_to_uint(buf[6],buf[7]); if (! useGlobalColormap) { if (ReadColorMap(fd, bitPixel, localColorMap)) { http://cvs.php.net/viewcvs.cgi/php-src/NEWS?r1=1.2027.2.549&r2=1.2027.2.550&diff_format=u Index: php-src/NEWS diff -u php-src/NEWS:1.2027.2.549 php-src/NEWS:1.2027.2.550 --- php-src/NEWS:1.2027.2.549 Sun May 7 18:00:28 2006 +++ php-src/NEWS Mon May 8 11:56:15 2006 @@ -3,7 +3,8 @@ ?? ??? 2006, PHP 5.?.? - Fixed bug #37313 (sigemptyset() used without including <signal.h>). (jdolecek) -- Fixed bug #37346 (invalid colormap format) +- Fixed bug #37346 (invalid colormap format) (Pierre) +- Fixed bug #37360 (invalid gif size) (Pierre) 04 May 2006, PHP 5.1.4 - Added "capture_peer_cert" and "capture_peer_cert_chain" context options http://cvs.php.net/viewcvs.cgi/php-src/ext/gd/tests/bug37360.phpt?view=markup&rev=1.1 Index: php-src/ext/gd/tests/bug37360.phpt +++ php-src/ext/gd/tests/bug37360.phpt --TEST-- Bug #37360 (gdimagecreatefromgif, bad image sizes) --SKIPIF-- <?php if (!extension_loaded('gd')) die("skip gd extension not available\n"); if (!GD_BUNDLED) die('skip external GD libraries always fail'); ?> --FILE-- <?php $im = imagecreatefromgif(dirname(__FILE__) . '/bug37360.gif'); var_dump($im); ?> --EXPECTF-- resource(%d) of type (gd) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php