PHP Bugs  
php.net | support | documentation | report a bug | advanced search | search howto | statistics | login

go to bug id or search bugs for  

Bug #37612 Segfault - infinite recursion
Submitted:27 May 2006 11:16am UTC Modified: 27 May 2006 12:27pm UTC
From:kevin at oceania dot net Assigned to:
Status:Bogus Category:Reproducible crash
Version:6, 5.2.0-cvs OS:Linux
View/Vote Developer Edit Submission

[27 May 2006 11:16am UTC] kevin at oceania dot net
Description:
------------
... infinite recursion
[Sat May 27 21:42:49 2006] [notice] child pid 10096 exit signal
Segmentation fault (11)
[Sat May 27 21:42:49 2006] [notice] child pid 10097 exit signal
Segmentation fault (11)

Reproduce code:
---------------
http://phpro.org/segfault.phps

Expected result:
----------------
output html table

Actual result:
--------------
(gdb) bt
#0 0x00bd5f1f in _int_malloc () from /lib/tls/libc.so.6
#1 0x00bd7f81 in malloc () from /lib/tls/libc.so.6
#2 0xf61f206b in _emalloc (size=44, __zend_filename=0xf634e1a0
"/home/kevin/html/php/dev/php5.2-200605230630/Zend/zend_vm_execute.h",
__zend_lineno=225, __zend_orig_filename=0x0, __zend_orig_lineno=0) at
/home/kevin/html/php/dev/php5.2-200605230630/Zend/zend_alloc.c:182
#3 0xf622947b in zend_do_fcall_common_helper_SPEC
(execute_data=0xfe34a200) at zend_vm_execute.h:225
#4 0xf6229fa0 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(execute_data=0xfe34a200) at zend_vm_execute.h:322
#5 0xf6228fd2 in execute (op_array=0xa157704) at zend_vm_execute.h:92
#6 0xf62294e8 in zend_do_fcall_common_helper_SPEC
(execute_data=0xfe34a350) at zend_vm_execute.h:234
#7 0xf6229fa0 in ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER
(execute_data=0xfe34a350) at zend_vm_execute.h:322
#8 0xf6228fd2 in execute (op_array=0xa157704) at zend_vm_execute.h:92
#9 0xf62294e8 in zend_do_fcall_common_helper_SPEC
(execute_data=0xfe34a4a0) at zend_vm_execute.h:234
[27 May 2006 12:14pm UTC] bjori@php.net
Shorter reproducible code:
<?php
class foo {
 public function bar() {
  return $this->bar();
 }
}
$foo = new foo();
$foo->bar();
?>
[27 May 2006 12:27pm UTC] tony2001@php.net
Yes, smashing the stack produces segfault and this is expected.

RSS feed | show source 

PHP Copyright © 2001-2009 The PHP Group
All rights reserved.
Last updated: Sat Nov 21 10:30:49 2009 UTC