From 26f7dbf522bd7473a47791384d73d5721bca8984 Mon Sep 17 00:00:00 2001 From: Michael Hamann Date: Mon, 2 May 2011 23:21:38 +0200 Subject: Add a test to do=check that should detect search index corruption With this test it should be possible to detect if the search index has been corrupted by using Rincewind RC or a git version of the weeks before the RC release. --- inc/indexer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'inc/indexer.php') diff --git a/inc/indexer.php b/inc/indexer.php index 107845e24..64e172b5b 100644 --- a/inc/indexer.php +++ b/inc/indexer.php @@ -1323,7 +1323,7 @@ function idx_listIndexLengths() { $dir = @opendir($conf['indexdir']); if ($dir === false) return array(); - $idx[] = array(); + $idx = array(); while (($f = readdir($dir)) !== false) { if (substr($f, 0, 1) == 'i' && substr($f, -4) == '.idx') { $i = substr($f, 1, -4); -- cgit v1.2.3