php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #37066 segfault in zend_assign_to_variable while debugging
Submitted: 2006-04-13 09:03 UTC Modified: 2006-04-13 09:20 UTC
From: it at absp dot alcatel dot be Assigned:
Status: Not a bug Package: Apache2 related
PHP Version: 5.1.2 OS: Linux 2.6.16-1.2080_FC5
Private report: No CVE-ID: None
 [2006-04-13 09:03 UTC] it at absp dot alcatel dot be
Description:
------------
The httpd child crashes whilst stepping through php code using DBG as debug module.  As soon as the first variable assignment is reached, it segfaults (11)

DBG php debugger, version 2.16.20, Copyright 2001, 2005 Dmitri Dmitrienko, http://www.nusphere.com/dbg

Version 	2.16.20
Linked 	as a shared library.
Dbg security 	enabled.
Profiler 	compiled, enabled
Target PHP version 	5.1.2
Server API 	Apache 2.0 Handler
Extensions API 	220051025
Modules API 	20050922
PHP API 	20041225



'./configure' '--disable-debug' '--with-pic' '--with-config-file-scan-dir=/usr/local/etc/php.d' '--disable-rpath' '--without-pear' '--with-bz2' '--with-curl' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--enable-gd-native-ttf' '--without-gdbm' '--with-gettext' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-png' '--with-pspell' '--with-expat-dir=/usr' '--with-pcre-regex=/usr' '--with-zlib' '--with-layout=GNU' '--enable-dom=shared' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-sysvmsg' '--enable-track-vars' '--enable-trans-sid' '--enable-yp' '--enable-wddx' '--with-kerberos' '--enable-ucd-snmp-hack' '--with-unixODBC=shared,/usr' '--enable-memory-limit' '--enable-shmop' '--enable-calendar' '--enable-dbx' '--enable-dio' '--with-mime-magic=/usr/local/apache2/conf/magic' '--without-sqlite' '--with-libxml-dir=/usr' '--with-xml' '--enable-force-cgi-redirect' '--enable-pcntl' '--with-imap=shared' '--with-imap-ssl' '--enable-mbstring=shared' '--enable-mbstr-enc-trans' '--enable-mbregex' '--with-ncurses=shared' '--with-gd=shared' '--enable-bcmath=shared' '--enable-dba=shared' '--with-db4=/usr' '--with-xmlrpc=shared' '--with-ldap=shared' '--with-mysql=shared,/usr' '--with-mysqli=shared,/usr/bin/mysql_config' '--with-dom-xslt=/usr' '--with-dom-exslt=/usr}' '--with-pgsql=shared' '--with-snmp=shared,/usr' '--enable-soap=shared' '--with-xsl=shared,/usr' '--enable-xmlreader=shared' '--enable-xmlwriter=shared' '--enable-fastcgi' '--enable-pdo=shared' '--with-pdo-odbc=shared,unixODBC,/usr' '--with-pdo-mysql=shared,/usr' '--with-pdo-pgsql=shared,/usr' '--with-pdo-sqlite=shared,/usr' '--with-apxs2=/usr/local/apache2/bin/apxs'


Reproduce code:
---------------
<?php
print("this works");
echo "and this";
$error="segfault when here";
?>

Expected result:
----------------
Stepping till end.

Actual result:
--------------
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208199504 (LWP 13969)]
0x01188435 in zend_assign_to_variable (result=0x909bcd0, op1=0x909bce4,
    op2=0x909bcf8, value=0x909bcfc, type=1, Ts=0xbf9e1bf0)
    at /data/misc/download/Download_spool/php-5.1.2/Zend/zend_execute.c:269
269             zval ***ptr = &CV_OF(node->u.var);


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-04-13 09:10 UTC] johannes@php.net
Do not file bugs when you have Zend extensions (zend_extension=)
loaded. Examples are Zend Optimizer, Zend Debugger, Turck MM Cache,
APC, Xdebug and ionCube loader.  These extensions often modify engine
behavior which is not related to PHP itself.

Please report this to the authors of the Debugger.
 [2006-04-13 09:20 UTC] it at absp dot alcatel dot be
Placed this bug on advice of the author debugger.

[quote]
thanks for the back trace.
It's clear that it's Zend crashed:
#0 zend_assign_to_variable() in /usr/src/debug/php-5.1.2/Zend/zend_execute.c
execution reached this point from Apache and DBG is not involved anyways.

I'd recommend you submit bug in http://bugs.php.net/
They will be happy to see backtrace too.

Seems im in the ping pong game.

Thanks anyway
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Nov 24 23:01:32 2024 UTC