summaryrefslogtreecommitdiff
path: root/Zend/zend_operators.h
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@zend.com>2019-06-06 01:40:40 +0300
committerDmitry Stogov <dmitry@zend.com>2019-06-06 01:40:40 +0300
commit90a2e4ba668e89e59301abfe71175b0c0d1f9b96 (patch)
tree813e7e390d68511866f84f21a536a91efafdb246 /Zend/zend_operators.h
parentbed8ae1d0f7fbd441d91a0676096957ea1b40722 (diff)
downloadphp-git-90a2e4ba668e89e59301abfe71175b0c0d1f9b96.tar.gz
Fixed reference-counting
Diffstat (limited to 'Zend/zend_operators.h')
-rw-r--r--Zend/zend_operators.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h
index 458ca66e2e..45c8305c34 100644
--- a/Zend/zend_operators.h
+++ b/Zend/zend_operators.h
@@ -287,7 +287,7 @@ static zend_always_inline void zend_tmp_string_release(zend_string *tmp) {
/* Like zval_get_string, but returns NULL if the conversion fails with an exception. */
static zend_always_inline zend_string *zval_try_get_string(zval *op) {
if (EXPECTED(Z_TYPE_P(op) == IS_STRING)) {
- return Z_STR_P(op);
+ return zend_string_copy(Z_STR_P(op));
} else {
return zval_try_get_string_func(op);
}