aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/cache
diff options
context:
space:
mode:
authorTristan Darricau <tristan.darricau@sensiolabs.com>2016-02-18 21:55:11 +0100
committerTristan Darricau <tristan.darricau@sensiolabs.com>2016-02-18 21:55:11 +0100
commit6e4ab6509b38f03daa2fb2af30df61423b126bdf (patch)
treeac8c696fc7e26ae2d98b507c62abb4bfcd630b2d /phpBB/phpbb/cache
parentfc66f00236230d41362dd63286641e8faffd0f99 (diff)
parentbd12427fd447dd4a3be89e8aa1656d0cbe7cc04a (diff)
downloadforums-6e4ab6509b38f03daa2fb2af30df61423b126bdf.tar
forums-6e4ab6509b38f03daa2fb2af30df61423b126bdf.tar.gz
forums-6e4ab6509b38f03daa2fb2af30df61423b126bdf.tar.bz2
forums-6e4ab6509b38f03daa2fb2af30df61423b126bdf.tar.xz
forums-6e4ab6509b38f03daa2fb2af30df61423b126bdf.zip
Merge pull request #4185 from marc1706/ticket/13681
[ticket/13681] Invalidate and reset opcache where necessary * marc1706/ticket/13681: [ticket/13681] Invalidate and reset opcache where necessary
Diffstat (limited to 'phpBB/phpbb/cache')
-rw-r--r--phpBB/phpbb/cache/driver/base.php5
-rw-r--r--phpBB/phpbb/cache/driver/file.php5
2 files changed, 10 insertions, 0 deletions
diff --git a/phpBB/phpbb/cache/driver/base.php b/phpBB/phpbb/cache/driver/base.php
index 4c20ad916d..53c50eeda3 100644
--- a/phpBB/phpbb/cache/driver/base.php
+++ b/phpBB/phpbb/cache/driver/base.php
@@ -61,6 +61,11 @@ abstract class base implements \phpbb\cache\driver\driver_interface
unset($this->sql_rowset);
unset($this->sql_row_pointer);
+ if (function_exists('opcache_reset'))
+ {
+ @opcache_reset();
+ }
+
$this->vars = array();
$this->sql_rowset = array();
$this->sql_row_pointer = array();
diff --git a/phpBB/phpbb/cache/driver/file.php b/phpBB/phpbb/cache/driver/file.php
index 9a7c4aec7f..fae4614039 100644
--- a/phpBB/phpbb/cache/driver/file.php
+++ b/phpBB/phpbb/cache/driver/file.php
@@ -568,6 +568,11 @@ class file extends \phpbb\cache\driver\base
fclose($handle);
+ if (function_exists('opcache_invalidate'))
+ {
+ @opcache_invalidate($file);
+ }
+
if (!function_exists('phpbb_chmod'))
{
global $phpbb_root_path;