Changeset 6361
- Timestamp:
- 12/07/07 15:16:33 (2 years ago)
- Files:
-
- trunk/lib/cache/sfEAcceleratorCache.class.php (modified) (1 diff)
- trunk/test/unit/cache/sfEAcceleratorCacheTest.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/lib/cache/sfEAcceleratorCache.class.php
r4586 r6361 107 107 } 108 108 109 eaccelerator_clean(); 109 $infos = eaccelerator_list_keys(); 110 if (is_array($infos)) 111 { 112 foreach ($infos as $info) 113 { 114 if (false !== strpos($info['name'], $this->prefix)) 115 { 116 // eaccelerator bug (http://eaccelerator.net/ticket/287) 117 $key = 0 === strpos($info['name'], ':') ? substr($info['name'], 1) : $info['name']; 118 if (!eaccelerator_rm($key)) 119 { 120 return false; 121 } 122 } 123 } 124 } 125 126 return true; 110 127 } 111 128 trunk/test/unit/cache/sfEAcceleratorCacheTest.php
r4957 r6361 14 14 $t = new lime_test($plan, new lime_output_color()); 15 15 16 if (!function_exists('eaccelerator_put') || !ini_get('eaccelerator.enable')) 16 try 17 17 { 18 $t->skip('EAccelerator needed to run these tests', $plan); 19 return; 18 $cache = new sfEAcceleratorCache(); 19 } 20 catch (sfInitializationException $e) 21 { 22 $t->skip($e->getMessage(), $plan); 20 23 } 21 24

