Skip to content

Commit 5372a1d

Browse files
committed
GH-9370: Fix opcache jit protection bits.
Allow mprotect to occur, pthread_jit_write_np are just to allow mprotect flags to be used.
1 parent aa702c5 commit 5372a1d

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

ext/opcache/jit/zend_jit.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4611,7 +4611,6 @@ ZEND_EXT_API void zend_jit_unprotect(void)
46114611
#ifdef HAVE_PTHREAD_JIT_WRITE_PROTECT_NP
46124612
if (zend_write_protect) {
46134613
pthread_jit_write_protect_np(0);
4614-
return;
46154614
}
46164615
#endif
46174616
opts |= PROT_EXEC;
@@ -4645,7 +4644,6 @@ ZEND_EXT_API void zend_jit_protect(void)
46454644
#ifdef HAVE_PTHREAD_JIT_WRITE_PROTECT_NP
46464645
if (zend_write_protect) {
46474646
pthread_jit_write_protect_np(1);
4648-
return;
46494647
}
46504648
#endif
46514649
if (mprotect(dasm_buf, dasm_size, PROT_READ | PROT_EXEC) != 0) {

0 commit comments

Comments
 (0)