mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3: Fix GH-16727: Opcache bad signal 139 crash in ZTS bookworm (frankenphp)
This commit is contained in:
commit
382be923ae
1 changed files with 7 additions and 1 deletions
|
@ -9146,7 +9146,13 @@ link_unbound:
|
||||||
}
|
}
|
||||||
|
|
||||||
opline->op1_type = IS_CONST;
|
opline->op1_type = IS_CONST;
|
||||||
LITERAL_STR(opline->op1, lcname);
|
/* It's possible that `lcname` is not an interned string because it was not yet in the interned string table.
|
||||||
|
* However, by this point another thread may have caused `lcname` to be added in the interned string table.
|
||||||
|
* This will cause `lcname` to get freed once it is found in the interned string table. If we were to use
|
||||||
|
* LITERAL_STR() here we would not change the `lcname` pointer to the new value, and it would point to the
|
||||||
|
* now-freed string. This will cause issues when we use `lcname` in the code below. We solve this by using
|
||||||
|
* zend_add_literal_string() which gives us the new value. */
|
||||||
|
opline->op1.constant = zend_add_literal_string(&lcname);
|
||||||
|
|
||||||
if (decl->flags & ZEND_ACC_ANON_CLASS) {
|
if (decl->flags & ZEND_ACC_ANON_CLASS) {
|
||||||
opline->opcode = ZEND_DECLARE_ANON_CLASS;
|
opline->opcode = ZEND_DECLARE_ANON_CLASS;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue