From: foobar Date: Thu, 6 Mar 2003 16:27:05 +0000 (+0000) Subject: Fixed bug #19943 (the memleaks) X-Git-Tag: RELEASE_0_5~589 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4a8abb2f3d68dc6bfd20f4f145734a4fdd378147;p=php Fixed bug #19943 (the memleaks) --- diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c index e6a9b16779..46897d0967 100644 --- a/Zend/zend_execute.c +++ b/Zend/zend_execute.c @@ -367,6 +367,7 @@ static inline void zend_assign_to_object_op(znode *result, znode *op1, znode *op if (object->type != IS_OBJECT) { zend_error(E_WARNING, "Attempt to assign property of non-object"); FREE_OP(Ts, op2, EG(free_op2)); + *retval = EG(uninitialized_zval_ptr); SELECTIVE_PZVAL_LOCK(*retval, result); @@ -466,9 +467,9 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2 T->EA.data.str_offset.str->value.str.val[T->EA.data.str_offset.offset] = final_value->value.str.val[0]; if (op2 - && op2->op_type == IS_VAR - && value==&T(op2->u.var).tmp_var) { - STR_FREE(value->value.str.val); + && op2->op_type != IS_VAR + && final_value == &T(op2->u.var).tmp_var) { + STR_FREE(final_value->value.str.val); } if (final_value == &tmp) { zval_dtor(final_value);