]> source.dussan.org Git - nextcloud-server.git/commitdiff
Allow usage of xCache variable cache if xcache_unset_by_prefix() is present.
authorAndreas Fischer <bantu@owncloud.com>
Thu, 15 Aug 2013 01:34:43 +0000 (03:34 +0200)
committerAndreas Fischer <bantu@owncloud.com>
Thu, 15 Aug 2013 01:34:43 +0000 (03:34 +0200)
lib/memcache/xcache.php

index e0acb11b0549bfa0c03765076ff7ee68daebe702..91b9810cc6b6de77c1d4253da1d507b5a08f8f85 100644 (file)
@@ -53,8 +53,10 @@ class XCache extends Cache {
                if (\OC::$CLI) {
                        return false;
                }
-               // as soon as admin auth is enabled we can run into issues with admin ops like xcache_clear_cache
-               if (ini_get('xcache.admin.enable_auth')) {
+               if (!function_exists('xcache_unset_by_prefix') && ini_get('xcache.admin.enable_auth')) {
+                       // We do not want to use xCache if we can not clear it without
+                       // using the administration function xcache_clear_cache()
+                       // AND administration functions are password-protected.
                        return false;
                }