Skip to content

Commit 31b4f39

Browse files
committed
Use ZVAL_NEW_STR() for new string in php_filter_encode_html()
1 parent 1a18012 commit 31b4f39

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/filter/sanitizing_filters.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ static void php_filter_encode_html(zval *value, const unsigned char *chars)
4949
}
5050

5151
zval_ptr_dtor(value);
52-
ZVAL_STR(value, smart_str_extract(&str));
52+
ZVAL_NEW_STR(value, smart_str_extract(&str));
5353
}
5454

5555
static const unsigned char hexchars[] = "0123456789ABCDEF";

0 commit comments

Comments
 (0)