Bug in APC object cache wp_cache_set() making it fail
-
In your drop in located at:
wp-content/object-cache.phpyou have:
` function wp_cache_set($id, $data, $group = ‘default’, $expire = 0) {
global $wp_object_cache;return $wp_object_cache->set($id, $data, $group, $expire);
}`This appears correct order of args ( KEY, DATA, GROUP, EXPIRY )
But then look into your APC implementation of
set()in file:w3-total-cache/lib/W3/Cache/Apc.phpyou have:
` function set($key, $var, $expire = 0, $group = ‘0’) {
$key = $this->get_item_key($key);$var[‘key_version’] = $this->_get_key_version($group);
return apc_store($key . ‘_’ . $this->_blog_id, serialize($var), $expire);
}`Notice you have got EXPIRY and GROUP the oposite way round. So group is getting set as expiry and visa-versa.
This breaks APC opcode functionality in the plugin and by switching them the correct way round opcode caching functions correctly…
The topic ‘Bug in APC object cache wp_cache_set() making it fail’ is closed to new replies.