]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/dird/dird.c
correct date
[bacula/bacula] / bacula / src / dird / dird.c
index 91d7dd4e0afa9a08e7dcaf9f9f24cce6c2ec0e7d..b4130421222ccb25418d89b9b262928c47c2d9b4 100644 (file)
@@ -97,7 +97,6 @@ int main (int argc, char *argv[])
    textdomain("bacula-dir");
    init_msg(NULL, NULL);             /* initialize message handler */
    daemon_start_time = time(NULL);
-   memset(&last_job, 0, sizeof(last_job));
 
    while ((ch = getopt(argc, argv, "c:d:fg:r:stu:v?")) != -1) {
       switch (ch) {
@@ -241,7 +240,7 @@ static void terminate_dird(int sig)
    delete_pid_file(director->pid_directory, "bacula-dir",  
                   director->DIRport);
    stop_watchdog();
-   signal(SIGCHLD, SIG_IGN);          /* don't worry about children now */
+// signal(SIGCHLD, SIG_IGN);          /* don't worry about children now */
    term_scheduler();
    if (runjob) {
       free(runjob);
@@ -398,9 +397,10 @@ Without that I don't know who I am :-(\n"), configfile);
                  if (db_create_counter_record(NULL, db, &cr)) {
                     counter->CurrentValue = cr.CurrentValue;
                     counter->created = true;
-//                   Dmsg2(000, "Create counter %s val=%d\n", counter->hdr.name, counter->CurrentValue);
+                     Dmsg2(100, "Create counter %s val=%d\n", counter->hdr.name, counter->CurrentValue);
                  }
-              } else {
+              } 
+              if (!counter->created) {
                  counter->CurrentValue = counter->MinValue;  /* default value */
               }
            }