diff options
author | Andi Gutmans <andi@php.net> | 2001-08-07 03:17:33 +0000 |
---|---|---|
committer | Andi Gutmans <andi@php.net> | 2001-08-07 03:17:33 +0000 |
commit | 5af7770a816fd74331afdee06e61acea184ac87d (patch) | |
tree | 33f971900976da98abd9585e593f0edde3f8671b /Zend/zend_variables.c | |
parent | 6737ea6fd45c12fcd1282f325202d652878afd26 (diff) | |
download | php-git-5af7770a816fd74331afdee06e61acea184ac87d.tar.gz |
- Sync Engine2 CVS with latest Engine CVS
Diffstat (limited to 'Zend/zend_variables.c')
-rw-r--r-- | Zend/zend_variables.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/Zend/zend_variables.c b/Zend/zend_variables.c index 5cb2ab5d60..757019860c 100644 --- a/Zend/zend_variables.c +++ b/Zend/zend_variables.c @@ -54,8 +54,7 @@ ZEND_API void _zval_dtor(zval *zvalue ZEND_FILE_LINE_DC) } break; case IS_OBJECT: - zend_hash_destroy(zvalue->value.obj.properties); - FREE_HASHTABLE(zvalue->value.obj.properties); + zvalue->value.obj.handlers.del_ref(zvalue->value.obj.handle); break; case IS_RESOURCE: { TSRMLS_FETCH(); @@ -119,14 +118,8 @@ ZEND_API int _zval_copy_ctor(zval *zvalue ZEND_FILE_LINE_DC) zend_hash_copy(zvalue->value.ht, original_ht, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *)); } break; - case IS_OBJECT: { - zval *tmp; - HashTable *original_ht = zvalue->value.obj.properties; - - ALLOC_HASHTABLE_REL(zvalue->value.obj.properties); - zend_hash_init(zvalue->value.obj.properties, 0, NULL, ZVAL_PTR_DTOR, 0); - zend_hash_copy(zvalue->value.obj.properties, original_ht, (copy_ctor_func_t) zval_add_ref, (void *) &tmp, sizeof(zval *)); - } + case IS_OBJECT: + zvalue->value.obj.handlers.add_ref(zvalue->value.obj.handle); break; } return SUCCESS; |