#32775 [Opn->Fbk]: PHP crashes with a segmentation fault on GD2 function
| From: | derick@php.net | Date: | Wed, 20 Apr 2005 09:49:59 +0000 |
| Subject: | #32775 [Opn->Fbk]: PHP crashes with a segmentation fault on GD2 function | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-77943@lists.php.net to get a copy of this message | ||
ID: 32775
Updated by: derick@php.net
Reported By: dirk dot msc at gmx dot de
-Status: Open
+Status: Feedback
Bug Type: Reproducible crash
Operating System: Linux
PHP Version: 5.0.4
New Comment:
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php
Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.
Previous Comments:
------------------------------------------------------------------------
[2005-04-20 11:46:25] dirk dot msc at gmx dot de
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 this bug report at http://bugs.php.net/?id=32775&edit=1