mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Fix VirtualProtect memory size
As otherwise it would remove executable flag from JIT memory Thanks Dmitry for the hint :)
This commit is contained in:
parent
771c64edcc
commit
f4628436df
1 changed files with 1 additions and 1 deletions
|
@ -626,7 +626,7 @@ void zend_accel_shared_protect(int mode)
|
|||
|
||||
for (i = 0; i < ZSMMG(shared_segments_count); i++) {
|
||||
DWORD oldProtect;
|
||||
if (!VirtualProtect(ZSMMG(shared_segments)[i]->p, ZSMMG(shared_segments)[i]->size, mode, &oldProtect)) {
|
||||
if (!VirtualProtect(ZSMMG(shared_segments)[i]->p, ZSMMG(shared_segments)[i]->end, mode, &oldProtect)) {
|
||||
zend_accel_error(ACCEL_LOG_ERROR, "Failed to protect memory");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue