We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f4b275b commit 4b34079Copy full SHA for 4b34079
1 file changed
Zend/zend_string.c
@@ -475,8 +475,8 @@ ZEND_API zend_string *zend_string_concat2(
475
const char *str1, size_t str1_len,
476
const char *str2, size_t str2_len)
477
{
478
- size_t len = zend_safe_address_guarded(1, str1_len, str2_len);
479
- zend_string *res = zend_string_alloc(len, 0);
+ size_t len = str1_len + str2_len;
+ zend_string *res = zend_string_safe_alloc(len, 0);
480
481
char *p = ZSTR_VAL(res);
482
p = zend_mempcpy(p, str1, str1_len);
0 commit comments