From 34fca81212ff2b530a59b0f8dcb234de59424403 Mon Sep 17 00:00:00 2001 From: bnu Date: Sat, 8 Feb 2014 13:58:52 +0900 Subject: [PATCH] =?UTF-8?q?fix=20#445=20APC=EC=97=90=EC=84=9C=20delete()?= =?UTF-8?q?=EA=B0=80=20null=EC=9D=84=20=EC=82=BD=EC=9E=85=ED=95=98?= =?UTF-8?q?=EB=8A=94=20=EB=AC=B8=EC=A0=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- classes/cache/CacheApc.class.php | 25 ++++++++++--------------- 1 file changed, 10 insertions(+), 15 deletions(-) diff --git a/classes/cache/CacheApc.class.php b/classes/cache/CacheApc.class.php index a416b1270..73abeb0b3 100644 --- a/classes/cache/CacheApc.class.php +++ b/classes/cache/CacheApc.class.php @@ -84,7 +84,7 @@ class CacheApc extends CacheBase if($modified_time > 0 && $modified_time > $obj[0]) { - $this->_delete($_key); + $this->delete($_key); return false; } @@ -110,24 +110,13 @@ class CacheApc extends CacheBase if($modified_time > 0 && $modified_time > $obj[0]) { - $this->_delete($_key); + $this->delete($_key); return false; } return $obj[1]; } - /** - * Delete variable from the cache(private) - * - * @param string $_key Used to store the value. - * @return void - */ - function _delete($_key) - { - $this->put($_key, null, 1); - } - /** * Delete variable from the cache * @@ -136,7 +125,7 @@ class CacheApc extends CacheBase */ function delete($key) { - $this->_delete($key); + return apc_delete($key); } /** @@ -149,7 +138,13 @@ class CacheApc extends CacheBase return apc_clear_cache('user'); } - + /** + * @DEPRECATED + */ + function _delete($key) + { + return $this->delete($key); + } } CacheApc::$isSupport = function_exists('apc_add');