cvs: ZendEngine2 / zend_execute.c
| From: | Stanislav Malyshev | Date: | Wed, 02 Jun 2004 12:48:20 +0000 |
| Subject: | cvs: ZendEngine2 / zend_execute.c | ||
| Groups: | php.zend-engine.cvs | ||
| Request: | Send a blank email to php-zend-engine-cvs+get-2679@lists.php.net to get a copy of this message | ||
stas Wed Jun 2 08:48:20 2004 EDT
Modified files:
/ZendEngine2 zend_execute.c
Log:
fix incdec - make value's refcount non-zero when passing to
write_property - otherwise __set caller cleanup could kill it.
http://cvs.php.net/diff.php/ZendEngine2/zend_execute.c?r1=1.647&r2=1.648&ty=u
Index: ZendEngine2/zend_execute.c
diff -u ZendEngine2/zend_execute.c:1.647 ZendEngine2/zend_execute.c:1.648
--- ZendEngine2/zend_execute.c:1.647 Fri May 28 04:55:10 2004
+++ ZendEngine2/zend_execute.c Wed Jun 2 08:48:19 2004
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: zend_execute.c,v 1.647 2004/05/28 08:55:10 helly Exp $ */
+/* $Id: zend_execute.c,v 1.648 2004/06/02 12:48:19 stas Exp $ */
#define ZEND_INTENSIVE_DEBUGGING 0
@@ -1275,11 +1275,9 @@
*retval = *z;
zendi_zval_copy_ctor(*retval);
incdec_op(z);
+ z->refcount++;
Z_OBJ_HT_P(object)->write_property(object, property, z TSRMLS_CC);
- if (z->refcount == 0) {
- zval_dtor(z);
- FREE_ZVAL(z);
- }
+ zval_ptr_dtor(&z);
}
FREE_OP(Ts, op2, EG(free_op2));