]> git.sur5r.net Git - bacula/bacula/commitdiff
Fix minor update slots bugs
authorKern Sibbald <kern@sibbald.com>
Fri, 28 May 2004 19:17:21 +0000 (19:17 +0000)
committerKern Sibbald <kern@sibbald.com>
Fri, 28 May 2004 19:17:21 +0000 (19:17 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@1371 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/src/stored/autochanger.c
bacula/src/stored/dircmd.c

index 5eb229500e1f648f2b10b44491ccc10739b6db65..60f428a2ce46fc5363d74f919ce8cfd6bce198e2 100644 (file)
@@ -85,7 +85,7 @@ int autoload_device(JCR *jcr, DEVICE *dev, int writing, BSOCK *dir)
         offline_or_rewind_dev(dev);
         /* We are going to load a new tape, so close the device */
         force_close_dev(dev);
-        if (loaded != 0) {        /* must unload drive */
+        if (loaded != 0 && loaded != -1) {        /* must unload drive */
             Dmsg0(400, "Doing changer unload.\n");
            Jmsg(jcr, M_INFO, 0, 
                  _("3303 Issuing autochanger \"unload slot %d, drive %d\" command.\n"),
index 43569da2b773436f69bfaddd64e0d53f88ec3edb..574e9d89ec4688ee7d04e0844f5901a90b36c365 100644 (file)
@@ -852,7 +852,8 @@ static void read_volume_label(JCR *jcr, DEVICE *dev, int Slot)
    dev->state &= ~ST_LABEL;          /* force read of label */
    switch (read_dev_volume_label(jcr, dev, block)) {               
    case VOL_OK:
-      bnet_fsend(dir, _("3001 Volume=\"%s\" Slot=%d\n"), dev->VolHdr.VolName, Slot);
+      /* DO NOT add quotes around the Volume name. It is scanned in the DIR */
+      bnet_fsend(dir, _("3001 Volume=%s Slot=%d\n"), dev->VolHdr.VolName, Slot);
       Dmsg1(100, "Volume: %s\n", dev->VolHdr.VolName);
       break;
    default: