mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-09-03 01:52:40 +00:00
Fixes improper return from Xcache::clear();
Adds test see #6110 git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@8046 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
0beda262d1
commit
96e84c2e60
2 changed files with 20 additions and 3 deletions
6
cake/libs/cache/xcache.php
vendored
6
cake/libs/cache/xcache.php
vendored
|
@ -107,12 +107,12 @@ class XcacheEngine extends CacheEngine {
|
|||
*/
|
||||
function clear() {
|
||||
$this->__auth();
|
||||
for ($i = 0, $max = xcache_count(XC_TYPE_VAR); $i < $max; $i++) {
|
||||
$max = xcache_count(XC_TYPE_VAR);
|
||||
for ($i = 0; $i < $max; $i++) {
|
||||
xcache_clear_cache(XC_TYPE_VAR, $i);
|
||||
}
|
||||
$result = xcache_count(XC_TYPE_VAR) == 0;
|
||||
$this->__auth(true);
|
||||
return $result;
|
||||
return true;
|
||||
}
|
||||
/**
|
||||
* Populates and reverses $_SERVER authentication values
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue