Bug #67491 [Nab]: Crush __debugInfo
| From: | imbolk at gmail dot com | Date: | Sat, 21 Jun 2014 18:33:46 +0000 |
| Subject: | Bug #67491 [Nab]: Crush __debugInfo | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-186284@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=67491&edit=1
ID: 67491
User updated by: imbolk at gmail dot com
Reported by: imbolk at gmail dot com
Summary: Crush __debugInfo
Status: Not a bug
Type: Bug
Package: *General Issues
Operating System: Mac OS X 10.9.3
PHP Version: 5.6.0RC1
Block user comment: N
Private report: N
New Comment:
Try to execute var_dump($GLOBALS); See how it crash? No?
Previous Comments:
------------------------------------------------------------------------
[2014-06-21 18:20:32] johannes@php.net
This is a "normal" stackoverflow due to infinite recursion - $GLOBALS includes $a so
$a's debugInfo is called over and over again.
------------------------------------------------------------------------
[2014-06-21 17:50:34] imbolk at gmail dot com
Description:
------------
Crush in __debugInfo then $GLOBALS returned.
Test script:
---------------
class A
{
public function __debugInfo()
{
return $GLOBALS;
}
}
$a = new A;
var_dump($a);
Expected result:
----------------
$GLOBALS output.
Actual result:
--------------
core dumped
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=67491&edit=1