From 9fc0517328a248825703bef90d631ec687fb0d58 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 1 Mar 2016 10:50:56 +0800 Subject: [PATCH] Fixed another segfault with file_cache_only now --- ext/opcache/zend_shared_alloc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ext/opcache/zend_shared_alloc.c b/ext/opcache/zend_shared_alloc.c index deae886991..663d905c8d 100644 --- a/ext/opcache/zend_shared_alloc.c +++ b/ext/opcache/zend_shared_alloc.c @@ -496,6 +496,10 @@ void zend_accel_shared_protect(int mode) #ifdef HAVE_MPROTECT int i; + if (!smm_shared_globals) { + return; + } + if (mode) { mode = PROT_READ; } else { -- 2.40.0