From: Zeev Suraski Date: Thu, 18 Mar 2004 14:03:58 +0000 (+0000) Subject: Fix possible data corruption with __set() X-Git-Tag: php-5.0.0RC1~3 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b8275175ff6aec4d6bf599339a918e8b9d31c1a3;p=php Fix possible data corruption with __set() --- diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index eaa575db4d..d256613a79 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -434,7 +434,6 @@ static inline void zend_assign_to_object(znode *result, zval **object_ptr, znode } Z_OBJ_HT_P(object)->write_dimension(object, property_name, value TSRMLS_CC); } - zval_ptr_dtor(&value); FREE_OP(Ts, op2, EG(free_op2)); if (result) { @@ -442,6 +441,7 @@ static inline void zend_assign_to_object(znode *result, zval **object_ptr, znode T(result->u.var).var.ptr_ptr = NULL; /* see if we can remove this */ SELECTIVE_PZVAL_LOCK(value, result); } + zval_ptr_dtor(&value); }