From 018b4576d17b2c4459fe0630dc377768f4930bfc Mon Sep 17 00:00:00 2001 From: Eric Bollengier Date: Thu, 19 Jun 2008 09:49:40 +0000 Subject: [PATCH] ebl Fix bug when restoring with a wrong mediatype git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/branches/Branch-2.4@7169 91ce42f0-d328-0410-95d8-f526ca767f89 --- .../2.4.1-restore-wrong-mediatype.patch | 26 +++++++++++++++++++ bacula/src/stored/acquire.c | 2 ++ bacula/technotes-2.3 | 3 +++ 3 files changed, 31 insertions(+) create mode 100644 bacula/patches/2.4.1-restore-wrong-mediatype.patch diff --git a/bacula/patches/2.4.1-restore-wrong-mediatype.patch b/bacula/patches/2.4.1-restore-wrong-mediatype.patch new file mode 100644 index 0000000000..6df1220534 --- /dev/null +++ b/bacula/patches/2.4.1-restore-wrong-mediatype.patch @@ -0,0 +1,26 @@ + This patch fixes complex restore where users choose a storage that doesn't + have the requested MediaType. + + Apply this patch to version 2.4.1 with: + + cd + patch -p0 < patches/2.4.1-restore-wrong-mediatype.patch + ./configure + make + ... + make install + + +Index: src/stored/acquire.c +=================================================================== +--- src/stored/acquire.c (revision 7148) ++++ src/stored/acquire.c (working copy) +@@ -331,6 +331,8 @@ + */ + if (dev->is_blocked()) { + dev->dunblock(DEV_LOCKED); ++ } else { ++ dev->dunlock(); /* dunblock() unlock the device too */ + } + Dmsg1(950, "jcr->dcr=%p\n", jcr->dcr); + return ok; diff --git a/bacula/src/stored/acquire.c b/bacula/src/stored/acquire.c index 37ff22cbee..55489403b9 100644 --- a/bacula/src/stored/acquire.c +++ b/bacula/src/stored/acquire.c @@ -331,6 +331,8 @@ get_out: */ if (dev->is_blocked()) { dev->dunblock(DEV_LOCKED); + } else { + dev->dunlock(); /* dunblock() unlock the device too */ } Dmsg1(950, "jcr->dcr=%p\n", jcr->dcr); return ok; diff --git a/bacula/technotes-2.3 b/bacula/technotes-2.3 index 0699fe85f7..98e3667437 100644 --- a/bacula/technotes-2.3 +++ b/bacula/technotes-2.3 @@ -1,6 +1,9 @@ Technical notes on version 2.2 General: +19Jun08 +ebl Fix bug when starting a restore on a storage that doesn't + have the requested MediaType. 18Jun08 kes More work on word alignments -- eliminate all ints from the configuration routines. -- 2.39.5