]> git.ipfire.org Git - thirdparty/bacula.git/commitdiff
Fix potential segfault in default bhash_info()
authorEric Bollengier <eric@baculasystems.com>
Mon, 1 Mar 2021 11:01:01 +0000 (12:01 +0100)
committerEric Bollengier <eric@baculasystems.com>
Thu, 24 Mar 2022 08:03:00 +0000 (09:03 +0100)
bacula/src/lib/org_lib_dedup.c

index 2871b25e0553b77c023880c14122a8b612ad7030..dda4030916db357f2700ef949f8e111bcc372b09 100644 (file)
@@ -21,7 +21,9 @@
 
 int bhash_info(int hash_id, const char **hash_name)
 {
-   *hash_name = "N/A";
+   if (hash_name) {
+      *hash_name = "N/A";
+   }
    return 0;
 }