]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/dird/dird.c
Turn off debug
[bacula/bacula] / bacula / src / dird / dird.c
index e1c1bd1c5c9d67d77413891671f0ec7ba9e384c6..9cdab0fb86320ba800712c806228b2cf89f74837 100644 (file)
@@ -69,6 +69,7 @@ DIRRES *director;                     /* Director resource */
 int FDConnectTimeout;
 int SDConnectTimeout;
 char *configfile = NULL;
+void *start_heap;
 
 /* Globals Imported */
 extern int r_first, r_last;           /* first and last resources */
@@ -127,6 +128,7 @@ int main (int argc, char *argv[])
    char *uid = NULL;
    char *gid = NULL;
 
+   start_heap = sbrk(0);
    setlocale(LC_ALL, "");
    bindtextdomain("bacula", LOCALEDIR);
    textdomain("bacula");
@@ -725,7 +727,7 @@ static bool check_resources()
       for (i=0; job_items[i].name; i++) {
          if (job_items[i].flags & ITEM_REQUIRED) {
                if (!bit_is_set(i, job->hdr.item_present)) {
-                  Jmsg(NULL, M_FATAL, 0, _("\"%s\" directive in Job \"%s\" resource is required, but not found.\n"),
+                  Jmsg(NULL, M_ERROR_TERM, 0, _("\"%s\" directive in Job \"%s\" resource is required, but not found.\n"),
                     job_items[i].name, job->name());
                   OK = false;
                 }
@@ -866,6 +868,7 @@ static bool check_catalog()
          if (db) {
             Jmsg(NULL, M_FATAL, 0, _("%s"), db_strerror(db));
             Pmsg1(000, "%s", db_strerror(db));
+            db_close_database(NULL, db);
          }
          OK = false;
          continue;