Skip to content

Commit 8d860c1

Browse files
committed
Fixed issue php#128 (opcache_invalidate segmentation fault)
1 parent fc9d886 commit 8d860c1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ext/opcache/ZendAccelerator.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1062,6 +1062,10 @@ int zend_accel_invalidate(const char *filename, int filename_len, zend_bool forc
10621062
realpath = accelerator_orig_zend_resolve_path(filename, filename_len TSRMLS_CC);
10631063
#endif
10641064

1065+
if (!realpath) {
1066+
return FAILURE;
1067+
}
1068+
10651069
persistent_script = zend_accel_hash_find(&ZCSG(hash), realpath, strlen(realpath) + 1);
10661070
if (persistent_script && !persistent_script->corrupted) {
10671071
zend_file_handle file_handle;

0 commit comments

Comments
 (0)