]> git.sur5r.net Git - bacula/bacula/blob - bacula/patches/1.36.2/1.36.2-store.patch
Commit NULL vol name patch
[bacula/bacula] / bacula / patches / 1.36.2 / 1.36.2-store.patch
1
2  This patch fails a job if no Storage resource is specified and
3  the job attempts to call the SD.
4
5  Apply the patch to 1.36.2 with:
6
7  cd <bacula-source>
8  patch -p0 <1.36.2-store.patch
9  make
10  ...
11
12 Index: src/dird/msgchan.c
13 ===================================================================
14 RCS file: /cvsroot/bacula/bacula/src/dird/msgchan.c,v
15 retrieving revision 1.32.4.1
16 diff -u -r1.32.4.1 msgchan.c
17 --- src/dird/msgchan.c  14 Feb 2005 10:02:21 -0000      1.32.4.1
18 +++ src/dird/msgchan.c  18 Mar 2005 15:40:53 -0000
19 @@ -66,6 +66,10 @@
20     BSOCK *sd;
21     STORE *store;
22  
23 +   if (!jcr->storage[0]) {
24 +      Jmsg(jcr, M_FATAL, 0, _("Attempt to contact the Storage daemon with no Storage resource.\n"));
25 +      return false;
26 +   }
27     store = (STORE *)jcr->storage[0]->first();
28  
29     /*