Bug #60444 [Opn]: Segmentation fault with include & class extending
| From: | laruence@php.net | Date: | Mon, 05 Dec 2011 08:20:18 +0000 |
| Subject: | Bug #60444 [Opn]: Segmentation fault with include & class extending | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-165668@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=60444&edit=1
ID: 60444
Updated by: laruence@php.net
Reported by: php-bugs at majkl578 dot cz
Summary: Segmentation fault with include & class extending
Status: Open
Type: Bug
Package: Reproducible crash
Operating System: Linux Debian
PHP Version: 5.4SVN-2011-12-05 (snap)
-Assigned To:
+Assigned To: dmitry
Block user comment: N
Private report: N
New Comment:
Hi dmitry, could you plz review this patch, thanks ;)
Previous Comments:
------------------------------------------------------------------------
[2011-12-05 08:19:31] laruence@php.net
The following patch has been added/updated:
Patch Name: bug60444.phpt
Revision: 1323073171
URL: https://bugs.php.net/patch-display.php?bug=60444&patch=bug60444.phpt&revision=1323073171
------------------------------------------------------------------------
[2011-12-05 08:18:58] laruence@php.net
The following patch has been added/updated:
Patch Name: bug60444.patch
Revision: 1323073138
URL: https://bugs.php.net/patch-display.php?bug=60444&patch=bug60444.patch&revision=1323073138
------------------------------------------------------------------------
[2011-12-05 02:44:39] php-bugs at majkl578 dot cz
Description:
------------
Crash on combination of class & include & extends.
Test script:
---------------
a.php:
<?php
class Foo
public function __construct() {
require_once __DIR__ . '/b.php';
Some::foo($this);
}
}
new Foo;
----------------------------------------------
b.php:
<?php
class Some {
public static function foo(Foo $foo) {}
}
class Bar extends Foo {}
----------------------------------------------
Now execute a.php.
Expected result:
----------------
no segfault
Actual result:
--------------
SIGSEGV
backtrace:
#0 0x0000000000a0e910 in ZEND_INIT_STATIC_METHOD_CALL_SPEC_CONST_CONST_HANDLER
(execute_data=0x7f7113df5200) at
/storage/build/php/5.4/php5.4-201112050130/Zend/zend_vm_execute.h:3399
#1 0x0000000000a02483 in execute (op_array=0x7f7113e2c290) at
/storage/build/php/5.4/php5.4-201112050130/Zend/zend_vm_execute.h:410
#2 0x00000000009c4c82 in zend_execute_scripts (type=8, retval=0x0, file_count=3) at
/storage/build/php/5.4/php5.4-201112050130/Zend/zend.c:1272
#3 0x000000000093a3b2 in php_execute_script (primary_file=0x7fffb311e710) at
/storage/build/php/5.4/php5.4-201112050130/main/main.c:2414
#4 0x0000000000b09d55 in do_cli (argc=2, argv=0x7fffb311eac8) at
/storage/build/php/5.4/php5.4-201112050130/sapi/cli/php_cli.c:983
#5 0x0000000000b0adea in main (argc=2, argv=0x7fffb311eac8) at
/storage/build/php/5.4/php5.4-201112050130/sapi/cli/php_cli.c:1356
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=60444&edit=1