From: Kern Sibbald Date: Sat, 2 Apr 2011 17:20:53 +0000 (+0200) Subject: Remove temp index on start and term of dbcheck X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=250ea07b780e8b7bf4f6b291e266d61ef82b76c6;p=bacula%2Fbacula Remove temp index on start and term of dbcheck --- diff --git a/bacula/src/tools/dbcheck.c b/bacula/src/tools/dbcheck.c index 7bdc0440d4..20a403bc9c 100644 --- a/bacula/src/tools/dbcheck.c +++ b/bacula/src/tools/dbcheck.c @@ -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();