commit | 7bb95dff569f465ad8887404c2f9d5304a2ff5b3 | [log] [tgz] |
---|---|---|
author | Sean Fisher <srtfisher@gmail.com> | Mon Jan 16 09:23:14 2012 -0500 |
committer | Sean Fisher <srtfisher@gmail.com> | Mon Jan 16 09:23:14 2012 -0500 |
tree | 3f49040d696e760381642f2d2ffa407cee1dc039 | |
parent | fc514ca3578c59753e059fd6b8a2415424850535 [diff] |
APC throws "apc_store() expects parameter 3 to be long, string given". Validates the TTL to an integer.
diff --git a/system/libraries/Cache/drivers/Cache_apc.php b/system/libraries/Cache/drivers/Cache_apc.php index 93993d0..a3dd469 100644 --- a/system/libraries/Cache/drivers/Cache_apc.php +++ b/system/libraries/Cache/drivers/Cache_apc.php
@@ -68,6 +68,7 @@ */ public function save($id, $data, $ttl = 60) { + $ttl = (int) $ttl; return apc_store($id, array($data, time(), $ttl), $ttl); }