php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26344 child pid xxxx exit signal Segmentation fault (11)
Submitted: 2003-11-21 04:06 UTC Modified: 2003-11-25 15:36 UTC
Votes:6
Avg. Score:4.7 ± 0.7
Reproduced:6 of 6 (100.0%)
Same Version:4 (66.7%)
Same OS:1 (16.7%)
From: james at vcv dot net Assigned:
Status: No Feedback Package: Reproducible crash
PHP Version: 4.3.4 OS: redhat 9
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2003-11-21 04:06 UTC] james at vcv dot net
Description:
------------
./configure \
--with-apxs2=/usr/local/apache_ssl/bin/apxs \
--with-config-file-path=/usr/local/lib \
--enable-track-vars=yes \
--with-pdflib=/usr/local/ \
--with-zlib-dir=/usr/lib/ \
--with-gd=../gd-2.0.15 \
--enable-gd-imgstrttf \
--with-jpeg-dir=/usr \
--with-png-dir=/usr \
--enable-gd-native-ttf \
--with-ming=/usr/local/src/ming-0.2a/php_ext \
--with-freetype-dir=/usr/local/include/freetype2/freetype/ \
--with-ttf=/usr/local/lib \
--enable-memory-limit \
--enable-debug \
--enable-sigchild

no change is made to the php.ini-dist 
phpinfo is at:
http://www.martysmom.com/phpinfo.php

tried gdb:

(gdb) run -X
Starting program: /usr/local/apache_ssl/bin/httpd -X
[New Thread 1075477920 (LWP 6941)]
Couldn't get registers: Operation not permitted.
(gdb) bt
Cannot fetch general-purpose registers for thread 1075477920: generic error
(gdb)


Reproduce code:
---------------
<?
$fontfile  = '/usr/local/fonts/truetype/VERDANAZ.TTF';
$image     = imagecreate(700, 300);
$backcolor = imagecolorallocate ($image, 128, 128, 85);
$forecolor = imagecolorallocate ($image, 155, 255, 255);
ImageFtText($image, 25, 15, 5, 125, $forecolor, $fontfile, "Hello World!", array("linespacing" => 0.5));
Header("Content-type: image/png");
ImagePNG($image);
ImageDestroy($image);
?>

Expected result:
----------------
"Hello World!" on a png graphic 700x300

Actual result:
--------------
sometimes I get the expected result and sometimes I get
"child pid xxxx exit signal Segmentation fault (11)"
from versions 4.3.2, 4.3.3, 4.3.4, php-5.0.0b2.

I always get the expected result from versions 4.3.1, 4.3.0


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2003-11-21 11:57 UTC] iliaa@php.net
Please generate a backtrace of the crash. Also, which model is your apache using?
 [2003-11-21 13:48 UTC] james at vcv dot net
Thank you for your help.

I have tried to generate backtrace using various methods:
HTTPD -X, (gdb) run -X, and php_cli but failed to get any result except what I provided in the first report 'Couldn't get registers: Operation not permitted.'

I upgraded gdb to latest version 6. It did not help. Somewhere I read that I need to upgrade the kernel for it to work. My current kernel is 2.4.20-8

Apache model:
httpd-2.0.48

./configure --prefix=/usr/local/apache_ssl \
--enable-modules="vhost_alias" \
--enable-ssl \
--with-ssl=/usr/local/openssl \
--enable-so
 [2003-11-21 21:27 UTC] sniper@php.net
1. Use the bundled GD library (just plain --with-gd)
2. Try ./configure --help to see what configure options exist and what they actually do..

For example, you don't need --enable-sigchild (known to cause problems)

And only use either Freetype 1 OR 2. Not both.
(remove --with-ttf)

 [2003-11-21 21:28 UTC] magnus@php.net
What MPM module are you using ? worker, prefork, other ?
 [2003-11-25 15:36 UTC] sniper@php.net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.


 [2004-03-13 13:24 UTC] ciprian at zuavra dot net
With 4.3.4 I've isolated the problem to using an external gd library. Using --with-gd=/opt/gd will produce the bug, using the internal GD lib with --with-gd won't produce it. Using freetype in GD has nothing to do with it, BTW.

gd 2.0.21, libpng 1.2.5, libjpeg 6b
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 00:01:29 2024 UTC