Skip to content

Commit e270ee3

Browse files
committed
memory_consumption must be page aligned
1 parent e0ca4dc commit e270ee3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/opcache/zend_accelerator_module.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ static ZEND_INI_MH(OnUpdateMemoryConsumption)
7171
return FAILURE;
7272
}
7373
if (UNEXPECTED(memsize > ZEND_LONG_MAX / (1024 * 1024))) {
74-
*p = ZEND_LONG_MAX;
74+
*p = ZEND_LONG_MAX & ~(1024 * 1024 - 1);
7575
} else {
7676
*p = memsize * (1024 * 1024);
7777
}

0 commit comments

Comments
 (0)