#32775 [NEW]: PHP crashes with a segmentation fault on GD2 function

From: Date: Wed, 20 Apr 2005 09:46:26 +0000
Subject: #32775 [NEW]: PHP crashes with a segmentation fault on GD2 function
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-77942@lists.php.net to get a copy of this message
From: dirk dot msc at gmx dot de Operating system: Linux PHP version: 5.0.4 PHP Bug Type: Reproducible crash Bug description: PHP crashes with a segmentation fault on GD2 function Description: ------------ The following script produces a segmentation fault on Linux whereas it works perfectly on Windows. You can find the image here: http://www.hdx4.com/neu/images/buttons/templates/border_top.gif Please download it as the URL may change. Reproduce code: --------------- $img = @imagecreatetruecolor (100, 21) or die ("Cannot Initialize new GD image stream"); $col_white=imagecolorallocate($img, 0xFF, 0xFF, 0xFF); imagefill($img, 0,0, $col_white); $top=@imagecreatefromgif("border_top.gif"); // $top=@imagecreatefrompng("default.png"); // if I use this one it works if ($top) { imagesettile($img, $top); imagefill($img, 0,0, IMG_COLOR_TILED); } header ("Content-type: image/png"); imagepng($img); imagedestroy($img); imagedestroy($top); Expected result: ---------------- Anything, but not a crash. -- Edit bug report at http://bugs.php.net/?id=32775&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=32775&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=32775&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=32775&r=trysnapshot51 Fixed in CVS: http://bugs.php.net/fix.php?id=32775&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=32775&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=32775&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=32775&r=needscript Try newer version: http://bugs.php.net/fix.php?id=32775&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=32775&r=support Expected behavior: http://bugs.php.net/fix.php?id=32775&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=32775&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=32775&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=32775&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=32775&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=32775&r=dst IIS Stability: http://bugs.php.net/fix.php?id=32775&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=32775&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=32775&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=32775&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=32775&r=mysqlcfg

« previous php.bugs (#77942) next »