php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #2158 Memory leak with global statement
Submitted: 1999-08-26 02:34 UTC Modified: 1999-08-26 03:27 UTC
From: christophe dot massiot at mail dot dotcom dot fr Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 4.0 Latest CVS (26/08/1999) OS: LinuxPPC R5/Linux 2.2.10
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: christophe dot massiot at mail dot dotcom dot fr
New email:
PHP Version: OS:

 

 [1999-08-26 02:34 UTC] christophe dot massiot at mail dot dotcom dot fr
The following script :
<?
global $toto;
$foobar = "coin";
?>

produces :

8:31 [webase3:pts/6] salome:~% php html/test.php 
Content-Type: text/html

html/test.php:  Freeing 0x018FE1E8 (5 bytes), allocated in zend_variables.c on line 120<br>

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-08-26 03:27 UTC] andi at cvs dot php dot net
Fixed in the latest CVS.
BTW, using global in the global scope doesn't really make sense. It's used inside functions to access variables which are in main variable table.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 03:01:27 2024 UTC