From b0b4fcfa5e9278782206339a16d9812ec4978ebf Mon Sep 17 00:00:00 2001 From: Marco van Wieringen Date: Tue, 25 Jan 2011 19:12:32 +0100 Subject: [PATCH] Fix logic inversion. --- bacula/src/tools/bbatch.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/bacula/src/tools/bbatch.c b/bacula/src/tools/bbatch.c index 189da9deb7..61f57ae632 100644 --- a/bacula/src/tools/bbatch.c +++ b/bacula/src/tools/bbatch.c @@ -110,7 +110,7 @@ static int list_handler(void *ctx, int num_fields, char **row) int main (int argc, char *argv[]) { int ch; - bool use_batch = true; + bool disable_batch = false; char *restore_list=NULL; setlocale(LC_ALL, ""); bindtextdomain("bacula", LOCALEDIR); @@ -131,10 +131,10 @@ int main (int argc, char *argv[]) restore_list=bstrdup(optarg); break; case 'B': - use_batch = false; + disable_batch = true; break; case 'b': - use_batch = true; + disable_batch = false; break; case 'd': /* debug level */ if (*optarg == 't') { @@ -197,7 +197,7 @@ int main (int argc, char *argv[]) /* To use the -r option, the catalog should already contains records */ if ((db = db_init_database(NULL, NULL, db_name, db_user, db_password, - db_host, 0, NULL, false, use_batch)) == NULL) { + db_host, 0, NULL, false, disable_batch)) == NULL) { Emsg0(M_ERROR_TERM, 0, _("Could not init Bacula database\n")); } if (!db_open_database(NULL, db)) { @@ -215,10 +215,10 @@ int main (int argc, char *argv[]) return 0; } - if (use_batch) { - printf("With new Batch mode\n"); - } else { + if (disable_batch) { printf("Without new Batch mode\n"); + } else { + printf("With new Batch mode\n"); } i = nb; -- 2.39.5