mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-8.0'
* PHP-8.0: Avoid dangling pointer in curl header.str
This commit is contained in:
commit
5adfcfe746
1 changed files with 1 additions and 3 deletions
|
@ -1626,9 +1626,7 @@ static int curl_debug(CURL *cp, curl_infotype type, char *buf, size_t buf_len, v
|
||||||
if (ch->header.str) {
|
if (ch->header.str) {
|
||||||
zend_string_release_ex(ch->header.str, 0);
|
zend_string_release_ex(ch->header.str, 0);
|
||||||
}
|
}
|
||||||
if (buf_len > 0) {
|
ch->header.str = zend_string_init(buf, buf_len, 0);
|
||||||
ch->header.str = zend_string_init(buf, buf_len, 0);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue