2 Bacula® - The Network Backup Solution
4 Copyright (C) 2001-2007 Free Software Foundation Europe e.V.
6 The main author of Bacula is Kern Sibbald, with contributions from
7 many others, a complete list can be found in the file AUTHORS.
8 This program is Free Software; you can redistribute it and/or
9 modify it under the terms of version two of the GNU General Public
10 License as published by the Free Software Foundation plus additions
11 that are listed in the file LICENSE.
13 This program is distributed in the hope that it will be useful, but
14 WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
23 Bacula® is a registered trademark of John Walker.
24 The licensor of Bacula is the Free Software Foundation Europe
25 (FSFE), Fiduciary Program, Sumatrastrasse 25, 8006 Zürich,
26 Switzerland, email:ftf@fsfeurope.org.
29 * Includes specific to the Director User Agent Server
31 * Kern Sibbald, August MMI
46 CONRES *cons; /* console resource */
47 POOLMEM *cmd; /* return command/name buffer */
48 POOLMEM *args; /* command line arguments */
49 char *argk[MAX_CMD_ARGS]; /* argument keywords */
50 char *argv[MAX_CMD_ARGS]; /* argument values */
51 int argc; /* number of arguments */
52 char **prompt; /* list of prompts */
53 int max_prompts; /* max size of list */
54 int num_prompts; /* current number in list */
55 int api; /* For programs want an API */
56 bool auto_display_messages; /* if set, display messages */
57 bool user_notified_msg_pending; /* set when user notified */
58 bool automount; /* if set, mount after label */
59 bool quit; /* if set, quit */
60 bool verbose; /* set for normal UA verbosity */
61 bool batch; /* set for non-interactive mode */
62 bool gui; /* set if talking to GUI program */
63 uint32_t pint32_val; /* positive integer */
64 int32_t int32_val; /* positive/negative */
65 int64_t int64_val; /* big int */
67 void signal(int sig) { UA_sock->signal(sig); };
69 /* The below are in ua_output.c */
70 void send_msg(const char *fmt, ...);
71 void error_msg(const char *fmt, ...);
72 void warning_msg(const char *fmt, ...);
73 void info_msg(const char *fmt, ...);
76 /* Context for insert_tree_handler() */
78 TREE_ROOT *root; /* root */
79 TREE_NODE *node; /* current node */
80 TREE_NODE *avail_node; /* unused node last insert */
81 int cnt; /* count for user feedback */
82 bool all; /* if set mark all as default */
84 uint32_t FileEstimate; /* estimate of number of files */
85 uint32_t FileCount; /* current count of files */
86 uint32_t LastCount; /* last count of files */
87 uint32_t DeltaCount; /* trigger for printing */
91 char **name; /* list of names */
92 int num_ids; /* ids stored */
93 int max_ids; /* size of array */
94 int num_del; /* number deleted */
95 int tot_ids; /* total to process */
99 /* Main structure for obtaining JobIds or Files to be restored */
104 char ClientName[MAX_NAME_LENGTH]; /* backup client */
105 char RestoreClientName[MAX_NAME_LENGTH]; /* restore client */
107 POOLMEM *JobIds; /* User entered string of JobIds */
112 uint32_t selected_files;
116 POOLMEM *fname; /* filename only */
117 POOLMEM *path; /* path only */
119 int fnl; /* filename length */
120 int pnl; /* path length */
122 bool all; /* mark all as default */
126 #define MAX_ID_LIST_LEN 2000000