summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Doyle <ddoyle@canadalawbook.ca>2005-09-06 23:40:43 +0200
committerDave Doyle <ddoyle@canadalawbook.ca>2005-09-06 23:40:43 +0200
commitd7c3763d432de58f39ae826bbcf80f5e8667171f (patch)
tree4ddfe3c694da8c4e17f93c9bf728866353089de5
parent31b5aa75594d3ec664758352dc297a3132584a9d (diff)
downloadrpg-d7c3763d432de58f39ae826bbcf80f5e8667171f.tar.gz
rpg-d7c3763d432de58f39ae826bbcf80f5e8667171f.tar.bz2
indexer rename bugfix for Win32
darcs-hash:20050906214043-a62d3-65097acf0b035fd6fe9833136a15f9562e69970f.gz
-rw-r--r--inc/indexer.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/inc/indexer.php b/inc/indexer.php
index 65ae126dd..e3af1fd4a 100644
--- a/inc/indexer.php
+++ b/inc/indexer.php
@@ -148,8 +148,12 @@ function idx_addPage($page){
// close the temp file and move it over to be the new one
fclose($tmp);
- return rename($conf['cachedir'].'/index.tmp',
- $conf['cachedir'].'/index.idx');
+ if(copy($conf['cachedir'].'/index.tmp',
+ $conf['cachedir'].'/index.idx')){
+ unlink($conf['cachedir'].'/index.tmp');
+ return true;
+ }
+ else{return false;}
}
/**