]> git.ipfire.org Git - thirdparty/bacula.git/commitdiff
Fix #10323 about bug in status storage with incorrect devices
authorEric Bollengier <eric@baculasystems.com>
Mon, 7 Aug 2023 09:22:04 +0000 (11:22 +0200)
committerEric Bollengier <eric@baculasystems.com>
Thu, 14 Sep 2023 11:57:01 +0000 (13:57 +0200)
bacula/src/stored/store_mngr.c

index 9e17ee65a94f524c46d54822de1b30bfffcea1b4..142aa6c537dc73abbef2db7684e7351131b782d0 100644 (file)
@@ -48,6 +48,10 @@ static bool build_query_size(DEVICE *dev, struct query_size **qs)
    struct stat statp;
    struct query_size *temp_qs;
 
+   if (!dev) {
+      return false;
+   }
+   
    /* Alloc helper struct, set correct size for this dev and add it to list
     * so that later we can sum size of all unique devices */
    temp_qs = (struct query_size *) malloc(sizeof(struct query_size));