summaryrefslogtreecommitdiff
path: root/main
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2005-03-28 18:46:57 (GMT)
committerIlia Alshanetsky <iliaa@php.net>2005-03-28 18:46:57 (GMT)
commit6071843d4c76bbade62fe6b9aa3bd12bc3b1b21d (patch)
treeca02c7e4801ac37809bdf78dac00d83aa4c3b679 /main
parentec841c8e124f9ef8c44212e7e330c3729fff5a3c (diff)
downloadphp-6071843d4c76bbade62fe6b9aa3bd12bc3b1b21d.tar.gz
Proper fix for the memory leak.
Diffstat (limited to 'main')
-rw-r--r--main/php_variables.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/main/php_variables.c b/main/php_variables.c
index 8379cfa..17a0d82 100644
--- a/main/php_variables.c
+++ b/main/php_variables.c
@@ -668,7 +668,7 @@ int php_hash_environment(TSRMLS_D)
}
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 @@ int php_hash_environment(TSRMLS_D)
}
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++;