]> granicus.if.org Git - php/commitdiff
Fixed string destruction (class_name might be reused and stored somewhere in __autolo...
authorDmitry Stogov <dmitry@zend.com>
Thu, 24 Jul 2014 10:11:21 +0000 (14:11 +0400)
committerDmitry Stogov <dmitry@zend.com>
Thu, 24 Jul 2014 10:11:21 +0000 (14:11 +0400)
Zend/zend_constants.c

index 650a566159713c61cf5b022512fceacae2052195..b134ed4cfe8ee1fa09752184aeb8697c375cb0f5 100644 (file)
@@ -398,7 +398,7 @@ ZEND_API zval *zend_get_constant_ex(zend_string *cname, zend_class_entry *scope,
                                ret_constant = Z_REFVAL_P(ret_constant);
                        }
                }
-               STR_FREE(class_name);
+               STR_RELEASE(class_name);
                STR_FREE(constant_name);
                if (ret_constant && Z_CONSTANT_P(ret_constant)) {
                        zval_update_constant_ex(ret_constant, 1, ce TSRMLS_CC);