]> git.sur5r.net Git - bacula/bacula/commitdiff
Correct Verify bugs
authorKern Sibbald <kern@sibbald.com>
Mon, 3 Jun 2002 13:30:42 +0000 (13:30 +0000)
committerKern Sibbald <kern@sibbald.com>
Mon, 3 Jun 2002 13:30:42 +0000 (13:30 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@34 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/src/dird/fd_cmds.c
bacula/src/dird/verify.c
bacula/src/version.h

index 6783d5eed17d8e67b4a8e71d5dd9dc78a8a74a80..304fb776122282aa4620f786413d4259004367b0 100644 (file)
@@ -212,7 +212,7 @@ msglen=%d msg=%s\n"), len, fd->msglen, fd->msg);
        }
 
        if (stream == STREAM_UNIX_ATTRIBUTES) {
-         jcr->jr.JobFiles++;
+         jcr->JobFiles++;
          len = strlen(fd->msg);      /* length before attributes */
          ar.attr = &fd->msg[len+1];
          ar.fname = jcr->fname;
@@ -248,7 +248,7 @@ msglen=%d msg=%s\n"), len, fd->msglen, fd->msg);
              Jmsg1(jcr, M_WARNING, 0, "%s", db_strerror(jcr->db));
          }
        }
-       jcr->jr.JobFiles = file_index;
+       jcr->jr.JobFiles = jcr->JobFiles = file_index;
        jcr->jr.LastIndex = file_index;
    } 
    if (n < 0) {
index 1039dbb9f16966671daa797203beda3906a9a34e..b296611974b5356ac7a43a230e2a8743e6fd1ddf 100644 (file)
@@ -48,11 +48,9 @@ extern int debug_level;
 
 /* Commands sent to File daemon */
 static char verifycmd[]   = "verify level=%s\n";
-static char levelcmd[]    = "level = %s%s\n";
 
 /* Responses received from File daemon */
 static char OKverify[]   = "2000 OK verify\n";
-static char OKlevel[]    = "2000 OK level\n";
 
 /* Forward referenced functions */
 static void verify_cleanup(JCR *jcr, int TermCode);
@@ -164,14 +162,9 @@ int do_verify(JCR *jcr)
          Jmsg1(jcr, M_FATAL, 0, _("Unimplemented save level %d\n"), jcr->JobLevel);
         goto bail_out;
    }
-   Dmsg1(20, ">filed: %s", fd->msg);
-   bnet_fsend(fd, levelcmd, level, " ");
-   if (!response(fd, OKlevel, "Level")) {
-      goto bail_out;
-   }
 
    /* 
-    * Send verify command to File daemon
+    * Send verify command/level to File daemon
     */
    bnet_fsend(fd, verifycmd, level);
    if (!response(fd, OKverify, "Verify")) {
@@ -201,11 +194,11 @@ int do_verify(JCR *jcr)
       goto bail_out;
    }
 
-   verify_cleanup(jcr, JS_Terminated);
+   verify_cleanup(jcr, jcr->JobStatus);
    return 1;
 
 bail_out:
-   verify_cleanup(jcr, JS_Terminated);
+   verify_cleanup(jcr, JS_ErrorTerminated);
    return 0;
 }
 
@@ -270,7 +263,7 @@ Termination:            %s\n\n"),
        jcr->client->hdr.name,
        sdt,
        edt,
-       edit_uint64_with_commas(jcr->jr.JobFiles, ec1),
+       edit_uint64_with_commas(jcr->JobFiles, ec1),
        term_msg);
 
    Dmsg0(100, "Leave verify_cleanup()\n");
@@ -322,7 +315,7 @@ int get_attributes_and_compare_to_catalog(JCR *jcr, int last_full_id)
        * Got attributes stream, decode it
        */
       if (stream == STREAM_UNIX_ATTRIBUTES) {
-        jcr->jr.JobFiles++;
+        jcr->JobFiles++;
         attr_file_index = file_index;    /* remember attribute file_index */
         len = strlen(fd->msg);
         attr = &fd->msg[len+1];
@@ -477,7 +470,7 @@ int get_attributes_and_compare_to_catalog(JCR *jcr, int last_full_id)
            do_MD5 = FALSE;
         }
       }
-      jcr->jr.JobFiles = file_index;
+      jcr->JobFiles = file_index;
    } 
    if (n < 0) {
       Jmsg2(jcr, M_FATAL, 0, _("bdird<filed: bad attributes from filed n=%d : %s\n"),
index 566250e86b7786fc424dfc17d2ce5b6b194b8134..8100d79869f0446f16391bb7e0f18a1121dc7a06 100644 (file)
@@ -1,8 +1,8 @@
 /* */
 #define VERSION "1.21"
 #define VSTRING "1"
-#define DATE    "2 June 2002"
-#define LSMDATE "02Jun02"
+#define DATE    "3 June 2002"
+#define LSMDATE "03Jun02"
 
 /* Debug flags */
 #define DEBUG 1