php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #34312 segfault in 5.04
Submitted: 2005-08-31 01:19 UTC Modified: 2005-09-02 16:29 UTC
From: james at academicsuperstore dot com Assigned:
Status: Closed Package: Reproducible crash
PHP Version: 5.0.4 OS: Debian 3.1 Linux 2.4.29
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: james at academicsuperstore dot com
New email:
PHP Version: OS:

 

 [2005-08-31 01:19 UTC] james at academicsuperstore dot com
Description:
------------
Segfault

Apache/2.0.53
Build Date 	Jun 8 2005 14:44:05

'./configure' '--prefix=/usr/local/php5' '--enable-force-cgi-redirect' '--disable-debug' '--enable-pic' '--disable-rpath' '--enable-inline-optimization' '--with-bz2-dir=/usr/bin/bzip2' '--with-gd=shared' '--enable-gd-native-ttf' '--without-gdbm' '--with-gmp' '--with-jpeg-dir=/usr' '--with-png' '--with-layout=GNU' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--with-mysql=/usr' '--with-pfpro=shared,/usr/local/src/verisign/payflowpro/linux/lib' '--enable-memory-limit' '--enable-mbstring=shared' '--enable-mbstr-enc-trans' '--disable-cgi' '--enable-cli' '--with-mm' '--with-zlib' '--with-apxs2=/usr/sbin/apxs' '--disable-libxml'

Reproduce code:
---------------
I do not have specific reproduce code as the segfault is part of a large and complex system.  I am posting the bug only after failing to be able to isolate the problem further.

Expected result:
----------------
no segfault

Actual result:
--------------
(gdb) bt
#0  0x003b859e in mallopt () from /lib/libc.so.6
#1  0x003b843e in mallopt () from /lib/libc.so.6
#2  0x003b715f in free () from /lib/libc.so.6
#3  0x0064f812 in _efree (ptr=0x85739e4)
    at /usr/local/src/php-5.0.4/Zend/zend_alloc.c:287
#4  0x00659f1c in destroy_op_array (op_array=0x856fad0)
    at /usr/local/src/php-5.0.4/Zend/zend_opcode.c:225
#5  0x00659c63 in destroy_zend_function (function=0x856fad0)
    at /usr/local/src/php-5.0.4/Zend/zend_opcode.c:103
#6  0x00659c79 in zend_function_dtor (function=0x856fad0)
    at /usr/local/src/php-5.0.4/Zend/zend_opcode.c:115
#7  0x00666b6c in zend_hash_del_key_or_index (ht=0x810f098,
    arKey=0x856f878 "dumpcatsforleftnav", nKeyLength=19, h=0, flag=0)
    at /usr/local/src/php-5.0.4/Zend/zend_hash.c:490
#8  0x006670b3 in zend_hash_reverse_apply (ht=0x810f098,
    apply_func=0x656e78 <is_not_internal_function>)
    at /usr/local/src/php-5.0.4/Zend/zend_hash.c:738
#9  0x00657389 in shutdown_executor ()
    at /usr/local/src/php-5.0.4/Zend/zend_execute_API.c:264
#10 0x00660eed in zend_deactivate ()
    at /usr/local/src/php-5.0.4/Zend/zend.c:817
#11 0x006320f5 in php_request_shutdown (dummy=0x0)
    at /usr/local/src/php-5.0.4/main/main.c:1216
#12 0x0069e048 in php_apache_request_dtor (r=0x82df078)
    at /usr/local/src/php-5.0.4/sapi/apache2handler/sapi_apache2.c:443
#13 0x0069e5a9 in php_handler (r=0x82df078)
    at /usr/local/src/php-5.0.4/sapi/apache2handler/sapi_apache2.c:572
#14 0x0807d429 in ap_run_handler (r=0x82df078) at config.c:152
#15 0x0807d973 in ap_invoke_handler (r=0x82df078) at config.c:364
#16 0x0807ad22 in ap_process_request (r=0x82df078) at http_request.c:249
#17 0x08076c8a in ap_process_http_connection (c=0x82d70e0) at http_core.c:251
#18 0x08085bb8 in ap_run_process_connection (c=0x82d70e0) at connection.c:43
#19 0x08085e7c in ap_process_connection (c=0x82d70e0, csd=0x82d7008)
    at connection.c:176
#20 0x0807c0b0 in child_main (child_num_arg=2) at prefork.c:610
#21 0x0807c20a in make_child (s=0x80f4058, slot=2) at prefork.c:704
#22 0x0807c261 in startup_children (number_to_start=5) at prefork.c:722
#23 0x0807c563 in ap_mpm_run (_pconf=0x80ba958, plog=0x80eca20, s=0x80f4058)
    at prefork.c:941
#24 0x08081d4e in main (argc=5, argv=0xbffffdd4) at main.c:618


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-09-01 17:48 UTC] sniper@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip


 [2005-09-01 20:57 UTC] james at academicsuperstore dot com
When I configure, make, make install using the same configure line as before I am left with a nonfunctioning php.  Hitting php pages just produces a white screen.  Even the cli php exits with code 1.  There are no cores or errors in the log.  Was something between 5.0.4 and the snapshot broken?  Sorry I can't test the fix.
 [2005-09-01 23:48 UTC] sniper@php.net
Check your httpd.conf that PHP is really enabled..

 [2005-09-02 01:45 UTC] james at academicsuperstore dot com
I didn't touch my httpd.conf.  I literally did a ./configure, make, make install, apachectl restart.  Plus even running just the cli php is borked, exits with message 1 no matter what options it is given.

Even something like:
php -r "echo 'test';"

just exits with message 1 and no output.
 [2005-09-02 07:24 UTC] sniper@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip

Try newer snapshot.
 [2005-09-02 07:24 UTC] sniper@php.net
And FYI: PHP touches httpd.conf when you do 'make install'..

 [2005-09-02 16:29 UTC] james at academicsuperstore dot com
Thanks, everything works as expected and the segfault is fixed.  When will 5.0.5 be out?
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue Jul 15 05:01:33 2025 UTC