From: Nikita Popov Date: Sat, 13 Sep 2014 21:30:32 +0000 (+0200) Subject: Fix use of stack variable outside its block X-Git-Tag: PRE_NATIVE_TLS_MERGE~158^2~85^2~44 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=eda5ba1f8fa935b8d1b8bae9d189c6afbe833287;p=php Fix use of stack variable outside its block --- diff --git a/Zend/zend_object_handlers.c b/Zend/zend_object_handlers.c index 956ff588f7..36c4efd882 100644 --- a/Zend/zend_object_handlers.c +++ b/Zend/zend_object_handlers.c @@ -659,12 +659,12 @@ found: } } } else if (EXPECTED(property_info != NULL)) { + zval tmp; + write_std_property: - /* if we assign referenced variable, we should separate it */ if (Z_REFCOUNTED_P(value)) { if (Z_ISREF_P(value)) { - zval tmp; - + /* if we assign referenced variable, we should separate it */ ZVAL_DUP(&tmp, Z_REFVAL_P(value)); value = &tmp; } else {