Initialize ping_auto_globals_mask to prevent undefined behaviour

Closes GH-10121
This commit is contained in:
Niels Dossche 2022-12-17 16:02:55 +01:00 committed by Ilija Tovilo
parent 6de376a2b4
commit c4487b7a12
No known key found for this signature in database
GPG Key ID: A4F5D403F118200A
2 changed files with 3 additions and 0 deletions

1
NEWS
View File

@ -15,6 +15,7 @@ PHP NEWS
- Opcache:
. Fix inverted bailout value in zend_runtime_jit() (Max Kellermann).
. Fix access to uninitialized variable in accel_preload(). (nielsdos)
- TSRM:
. Fixed Windows shmget() wrt. IPC_PRIVATE. (Tyson Andre)

View File

@ -4444,6 +4444,8 @@ static int accel_preload(const char *config, bool in_child)
if (PG(auto_globals_jit)) {
ping_auto_globals_mask = zend_accel_get_auto_globals();
} else {
ping_auto_globals_mask = 0;
}
if (EG(zend_constants)) {