iliaa           Mon Mar 28 13:46:58 2005 EDT

  Modified files:              
    /php-src/main       php_variables.c 
  Log:
  Proper fix for the memory leak.
  
  
http://cvs.php.net/diff.php/php-src/main/php_variables.c?r1=1.86&r2=1.87&ty=u
Index: php-src/main/php_variables.c
diff -u php-src/main/php_variables.c:1.86 php-src/main/php_variables.c:1.87
--- php-src/main/php_variables.c:1.86   Mon Mar 28 13:09:28 2005
+++ php-src/main/php_variables.c        Mon Mar 28 13:46:57 2005
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_variables.c,v 1.86 2005/03/28 18:09:28 iliaa Exp $ */
+/* $Id: php_variables.c,v 1.87 2005/03/28 18:46:57 iliaa Exp $ */
 
 #include <stdio.h>
 #include "php.h"
@@ -668,7 +668,7 @@
        }
 
        for (i=0; i<num_track_vars; i++) {
-               if ((jit_initialization && 
auto_global_records[i].jit_initialization) || _gpc_flags[i]) {
+               if (jit_initialization && 
auto_global_records[i].jit_initialization) {
                        continue;
                }
                if (!PG(http_globals)[i]) {
@@ -684,7 +684,6 @@
                }
 
                zend_hash_update(&EG(symbol_table), 
auto_global_records[i].name, auto_global_records[i].name_len, 
&PG(http_globals)[i], sizeof(zval *), NULL);
-               PG(http_globals)[i]->refcount++;
                if (PG(register_long_arrays)) {
                        zend_hash_update(&EG(symbol_table), 
auto_global_records[i].long_name, auto_global_records[i].long_name_len, 
&PG(http_globals)[i], sizeof(zval *), NULL);
                        PG(http_globals)[i]->refcount++;

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to