From 1feae1cf5e980d657821ecde3b612494b2133bb2 Mon Sep 17 00:00:00 2001 From: Kern Sibbald Date: Mon, 7 Jul 2014 09:50:56 +0200 Subject: [PATCH] Fix possible seg fault --- bacula/src/dird/ua_label.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/bacula/src/dird/ua_label.c b/bacula/src/dird/ua_label.c index 84d42b0f8e..012f337453 100644 --- a/bacula/src/dird/ua_label.c +++ b/bacula/src/dird/ua_label.c @@ -302,8 +302,9 @@ void update_slots(UAContext *ua) db_unlock(ua->db); bail_out: - - free_vol_list(vol_list); + if (vol_list) { + free_vol_list(vol_list); + } free(slot_list); close_sd_bsock(ua); -- 2.39.5