]> git.sur5r.net Git - bacula/bacula/commitdiff
Debug code
authorKern Sibbald <kern@sibbald.com>
Fri, 11 Apr 2008 15:42:17 +0000 (15:42 +0000)
committerKern Sibbald <kern@sibbald.com>
Fri, 11 Apr 2008 15:42:17 +0000 (15:42 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@6797 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/src/stored/acquire.c
bacula/src/stored/device.c

index 51474e2a1344d5f1c8fbbd67a842b67057a987d9..58ed74db62c0d7486f2ed562f21952065fc5b996 100644 (file)
@@ -469,7 +469,8 @@ bool release_device(DCR *dcr)
       dev->num_writers--;
       Dmsg1(100, "There are %d writers in release_device\n", dev->num_writers);
       if (dev->is_labeled()) {
-         Dmsg0(100, "dir_create_jobmedia_record. Release\n");
+         Dmsg2(200, "dir_create_jobmedia. Release vol=%s dev=%s\n", 
+               dev->VolCatInfo.VolCatName, dev->print_name());
          if (!dev->at_weot() && !dir_create_jobmedia_record(dcr)) {
             Jmsg(jcr, M_FATAL, 0, _("Could not create JobMedia record for Volume=\"%s\" Job=%s\n"),
                dcr->VolCatInfo.VolCatName, jcr->Job);
@@ -479,14 +480,15 @@ bool release_device(DCR *dcr)
             dev->weof(1);
             write_ansi_ibm_labels(dcr, ANSI_EOF_LABEL, dev->VolHdr.VolumeName);
          }
-         if (!dev->num_writers) {             /* if no more writers */
-            volume_unused(dcr);               /*  we obviously are not using the volume */
-         }
          if (!dev->at_weot()) {
             dev->VolCatInfo.VolCatFiles = dev->file;   /* set number of files */
             /* Note! do volume update before close, which zaps VolCatInfo */
-            Dmsg0(100, "dir_update_vol_info. Release0\n");
             dir_update_volume_info(dcr, false, false); /* send Volume info to Director */
+            Dmsg2(200, "dir_update_vol_info. Release vol=%s dev=%s\n", 
+                  dev->VolCatInfo.VolCatName, dev->print_name());
+         }
+         if (!dev->num_writers) {             /* if no more writers */
+            volume_unused(dcr);               /*  we obviously are not using the volume */
          }
       }
 
index 0d84404ea744bfc414c97cab5f1dcdcb8d7c4b4e..0006cdf6d1fd9dd9960fb5909caf7e1707678b14 100644 (file)
@@ -159,7 +159,7 @@ bool fixup_device_block_write_error(DCR *dcr)
    /*
     * Walk through all attached jcrs indicating the volume has changed
     */
-   Dmsg1(100, "Walk attached dcrs. Volume=%s\n", dev->VolCatInfo.VolCatName);
+   Dmsg1(100, "Notify vol change. Volume=%s\n", dev->VolCatInfo.VolCatName);
    DCR *mdcr;
    foreach_dlist(mdcr, dev->attached_dcrs) {
       JCR *mjcr = mdcr->jcr;