Skip to content

Commit 956ac5c

Browse files
committed
Fixed possible assertion/crash when PHP script can't be stored in SHM (e.g. because another process already did this)
1 parent 2aff1cb commit 956ac5c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/opcache/zend_accelerator_util_funcs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -581,7 +581,7 @@ static void zend_accel_class_hash_copy(HashTable *target, HashTable *source)
581581
p = source->arData;
582582
end = p + source->nNumUsed;
583583
for (; p != end; p++) {
584-
ZEND_ASSERT(Z_TYPE(p->val) != IS_UNDEF);
584+
if (UNEXPECTED(Z_TYPE(p->val) == IS_UNDEF)) continue;
585585
ZEND_ASSERT(p->key);
586586
t = zend_hash_find_ex(target, p->key, 1);
587587
if (UNEXPECTED(t != NULL)) {

0 commit comments

Comments
 (0)