]> git.sur5r.net Git - bacula/bacula/commitdiff
Free jcr in btape before other pointers
authorKern Sibbald <kern@sibbald.com>
Sun, 6 Nov 2011 15:00:01 +0000 (16:00 +0100)
committerKern Sibbald <kern@sibbald.com>
Sat, 20 Apr 2013 12:50:12 +0000 (14:50 +0200)
bacula/src/stored/btape.c

index d70da195c28daed32218b989fcc4bb41ba8ef4a0..2b19e62e782188d202e619d2fd100befb36cc5bf 100644 (file)
@@ -318,6 +318,9 @@ static void terminate_btape(int stat)
 {
 
    Dsm_check(200);
+   free_jcr(jcr);
+   jcr = NULL;
+
    if (configfile) {
       free(configfile);
    }
@@ -339,8 +342,6 @@ static void terminate_btape(int stat)
       free_bsr(bsr);
    }
 
-   free_jcr(jcr);
-   jcr = NULL;
 
    free_volume_lists();