Skip to content

Commit 8946b7b

Browse files
KoudelkaBiluuu1994
authored andcommitted
Access violation when ALLOC_FALLBACK fixed
Close phpGH-11312
1 parent 6267601 commit 8946b7b

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

Diff for: NEWS

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ PHP NEWS
44

55
- Opcache:
66
. Fix allocation loop in zend_shared_alloc_startup(). (nielsdos)
7+
. Access violation on smm_shared_globals with ALLOC_FALLBACK. (KoudelkaB)
78

89
- Standard:
910
. Fix access on NULL pointer in array_merge_recursive(). (ilutov)

Diff for: ext/opcache/zend_shared_alloc.c

+2
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ int zend_shared_alloc_startup(size_t requested_size, size_t reserved_size)
191191
}
192192
#if ENABLE_FILE_CACHE_FALLBACK
193193
if (ALLOC_FALLBACK == res) {
194+
smm_shared_globals = NULL;
194195
return ALLOC_FALLBACK;
195196
}
196197
#endif
@@ -216,6 +217,7 @@ int zend_shared_alloc_startup(size_t requested_size, size_t reserved_size)
216217
}
217218
#if ENABLE_FILE_CACHE_FALLBACK
218219
if (ALLOC_FALLBACK == res) {
220+
smm_shared_globals = NULL;
219221
return ALLOC_FALLBACK;
220222
}
221223
#endif

0 commit comments

Comments
 (0)