]> git.sur5r.net Git - bacula/bacula/commitdiff
Remove temp index on start and term of dbcheck
authorKern Sibbald <kern@sibbald.com>
Sat, 2 Apr 2011 17:20:53 +0000 (19:20 +0200)
committerKern Sibbald <kern@sibbald.com>
Sat, 2 Apr 2011 17:22:11 +0000 (19:22 +0200)
bacula/src/tools/dbcheck.c

index 7bdc0440d4181a1fa1b0b10974bdca8ad55a95d5..20a403bc9cf1a4e9db4a3fb9c80bfa76fcfc4b49 100644 (file)
@@ -1,7 +1,7 @@
 /*
    Bacula® - The Network Backup Solution
 
-   Copyright (C) 2002-2009 Free Software Foundation Europe e.V.
+   Copyright (C) 2002-2011 Free Software Foundation Europe e.V.
 
    The main author of Bacula is Kern Sibbald, with contributions from
    many others, a complete list can be found in the file AUTHORS.
@@ -32,8 +32,6 @@
  *
  *   Kern E. Sibbald, August 2002
  *
- *   Version $Id$
- *
  */
 
 #include "bacula.h"
@@ -307,6 +305,9 @@ int main (int argc, char *argv[])
           return 1;
    }
 
+   /* drop temporary index idx_tmp_name if it already exists */
+   drop_tmp_idx("idxPIchk", "File");
+
    if (batch) {
       repair_bad_paths();
       repair_bad_filenames();
@@ -325,6 +326,9 @@ int main (int argc, char *argv[])
       do_interactive_mode();
    }
 
+   /* drop temporary index idx_tmp_name */
+   drop_tmp_idx("idxPIchk", "File");
+
    db_close_database(NULL, db);
    close_msg(NULL);
    term_msg();