From: skissane at ics dot mq dot edu dot au
Operating system: RedHat Linux 9
PHP version: 4.3.3
PHP Bug Type: Reproducible crash
Bug description: PHP segmentation fault
Description:
------------
PHP segfaults.
Reproduce code:
---------------
Reproduce code can be found at:
http://www.iips.mq.edu.au/bugs/
File datamodel/cms-datamodel-php.php causes crash.
Through trial and error (insertion of "echo" and "exit" statements, I
believe I have isolated the segfault to the function
ObjectGenerator_PHP::_generateEnums() in the file
appgen/ObjectGenerator_PHP.inc, but not 100% sure).
Segfault occurs both on command line php and through Apache.
PHP was compiled myself using: './configure' '--with-apxs2=/usr/sbin/apxs'
'--with-mysql=/usr/' '--without-mssql' '--with-ldap'
'--with-curl=/usr'
Expected result:
----------------
No segfault
Actual result:
--------------
Starting program: /usr/local/bin/php cms-datamodel-php.php
Program received signal SIGSEGV, Segmentation fault.
0x42074760 in _int_free () from /lib/tls/libc.so.6
(gdb) bt
#0 0x42074760 in _int_free () from /lib/tls/libc.so.6
#1 0x42073786 in free () from /lib/tls/libc.so.6
#2 0x08104302 in _efree (ptr=0x82cd0bc) at
/home/skissane/php-4.3.3/Zend/zend_alloc.c:265
#3 0x0810a85a in _zval_ptr_dtor (zval_ptr=0x8312c48) at
zend_execute.h:44
#4 0x08115e70 in zend_hash_destroy (ht=0x832c41c) at
/home/skissane/php-4.3.3/Zend/zend_hash.c:553
#5 0x08110aae in _zval_dtor (zvalue=0xbfffa9e0) at
/home/skissane/php-4.3.3/Zend/zend_variables.c:51
#6 0x0811f611 in execute (op_array=0x81eaf7c) at
/home/skissane/php-4.3.3/Zend/zend_execute.c:1452
#7 0x0811e653 in execute (op_array=0x81eadd4) at
/home/skissane/php-4.3.3/Zend/zend_execute.c:1660
#8 0x0811e653 in execute (op_array=0x81a2004) at
/home/skissane/php-4.3.3/Zend/zend_execute.c:1660
#9 0x08111fd5 in zend_execute_scripts (type=8, retval=0x0, file_count=3)
at /home/skissane/php-4.3.3/Zend/zend.c:885
#10 0x080ecb87 in php_execute_script (primary_file=0xbfffddc0) at
/home/skissane/php-4.3.3/main/main.c:1723
#11 0x081234bb in main (argc=2, argv=0xbfffde44) at
/home/skissane/php-4.3.3/sapi/cli/php_cli.c:818
#12 0x420156a4 in __libc_start_main () from /lib/tls/libc.so.6
(gdb) frame 6
#6 0x0811f611 in execute (op_array=0x81eaf7c) at
/home/skissane/php-4.3.3/Zend/zend_execute.c:1452
1452
zendi_zval_dtor(EX(Ts)[EX(opline)->op1.u.var].tmp_var);
(gdb)
--
Edit bug report at http://bugs.php.net/?id=25289&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=25289&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=25289&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=25289&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=25289&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=25289&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=25289&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=25289&r=support
Expected behavior: http://bugs.php.net/fix.php?id=25289&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=25289&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=25289&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=25289&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25289&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=25289&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=25289&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=25289&r=gnused