X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=bacula%2Fsrc%2Fdird%2Fua_input.c;h=d264d10272051881ff187334b691500965a9ebed;hb=c5f4a68937116a768e6d85bc576a5fd41a56e93a;hp=2b16f507433fc1e260febb4346fe5e8ae18faa66;hpb=2bdf88b4afde8c9fbad936be9d02d3ed82d550a5;p=bacula%2Fbacula diff --git a/bacula/src/dird/ua_input.c b/bacula/src/dird/ua_input.c index 2b16f50743..d264d10272 100644 --- a/bacula/src/dird/ua_input.c +++ b/bacula/src/dird/ua_input.c @@ -1,7 +1,7 @@ /* Bacula® - The Network Backup Solution - Copyright (C) 2001-2008 Free Software Foundation Europe e.V. + Copyright (C) 2001-2010 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. @@ -31,7 +31,6 @@ * * Kern Sibbald, October MMI * - * Version $Id$ */ #include "bacula.h" @@ -56,11 +55,11 @@ int get_cmd(UAContext *ua, const char *prompt, bool subprompt) if (!sock || ua->batch) { /* No UA or batch mode */ return 0; } - if (!subprompt) { + if (!subprompt && ua->api) { sock->signal(BNET_TEXT_INPUT); } sock->fsend("%s", prompt); - if (subprompt) { + if (!ua->api || subprompt) { sock->signal(BNET_SUB_PROMPT); } for ( ;; ) {