php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #17000 casting GLOBALS to object causes segfault.
Submitted: 2002-05-04 01:11 UTC Modified: 2002-08-19 08:01 UTC
Votes:2
Avg. Score:4.0 ± 1.0
Reproduced:2 of 2 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: alan at akbkhome dot com Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 4.2.0 OS: linux (debian)
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: alan at akbkhome dot com
New email:
PHP Version: OS:

 

 [2002-05-04 01:11 UTC] alan at akbkhome dot com
simple script
<?
$t = (object) $GLOBALS;
?>

result = segfault.

Workaround (dont do it!)

Backtrace

Program received signal SIGSEGV, Segmentation fault.
0x4014dd4d in free () from /lib/libc.so.6
(gdb) bt
#0  0x4014dd4d in free () from /lib/libc.so.6
#1  0x4014dc13 in free () from /lib/libc.so.6
#2  0x80c51b0 in shutdown_memory_manager (silent=0, clean_cache=0)
    at zend_alloc.c:484
#3  0x805d3ee in php_request_shutdown (dummy=0x0) at main.c:794
#4  0x805c190 in main (argc=2, argv=0xbffffc54) at cgi_main.c:834
#5  0x400f86cf in __libc_start_main () from /lib/libc.so.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-08-19 08:01 UTC] iliaa@php.net
This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sun Jul 27 02:00:03 2025 UTC