Index: trunk/admin/xcache.php
===================================================================
--- trunk/admin/xcache.php	(revision 934)
+++ trunk/admin/xcache.php	(revision 976)
@@ -239,5 +239,5 @@
 		if (isset($_POST['clearcache'])) {
 			$count = xcache_count($type);
-			if ($cacheid == $count) {
+			if ($cacheid >= 0) {
 				for ($cacheid = 0; $cacheid < $count; $cacheid ++) {
 					xcache_clear_cache($type, $cacheid);
@@ -245,5 +245,5 @@
 			}
 			else {
-				xcache_clear_cache($type, $cacheid);
+				xcache_clear_cache($type);
 			}
 		}
@@ -272,5 +272,5 @@
 	$total['type'] = XC_TYPE_PHP;
 	$total['cache_name'] = _T('Total');
-	$total['cacheid'] = $pcnt;
+	$total['cacheid'] = -1;
 	$total['gc'] = null;
 	$total['istotal'] = true;
@@ -296,5 +296,5 @@
 	$total['type'] = XC_TYPE_VAR;
 	$total['cache_name'] = _T('Total');
-	$total['cacheid'] = $vcnt;
+	$total['cacheid'] = -1;
 	$total['gc'] = null;
 	$total['istotal'] = true;
