summaryrefslogtreecommitdiffstats
path: root/src/H5MF.c
diff options
context:
space:
mode:
authorBinh-Minh Ribler <bmribler@hdfgroup.org>2020-08-17 22:51:15 (GMT)
committerBinh-Minh Ribler <bmribler@hdfgroup.org>2020-08-17 22:51:15 (GMT)
commit5bb893a2c2bcba6e8bebc99ee1a506599111b716 (patch)
tree2376094a0e27ae00fa4e4e06004b0e832a2882ea /src/H5MF.c
parent0f9c22edc75715bd0a6e702b1c8c929650065d70 (diff)
downloadhdf5-5bb893a2c2bcba6e8bebc99ee1a506599111b716.zip
hdf5-5bb893a2c2bcba6e8bebc99ee1a506599111b716.tar.gz
hdf5-5bb893a2c2bcba6e8bebc99ee1a506599111b716.tar.bz2
Fix HDFFV-11101
Description Added initialization to local structs in the src function H5MF_settle_raw_data_fsm() and the test function test_bt2_hdr_fd() to prevent the following error in two different occurrences: MemorySanitizer: use-of-uninitialized-value Platforms tested: Linux/64 (jelly) Linux/64 (platypus)
Diffstat (limited to 'src/H5MF.c')
-rw-r--r--src/H5MF.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/H5MF.c b/src/H5MF.c
index aa65db2..5e61751 100644
--- a/src/H5MF.c
+++ b/src/H5MF.c
@@ -2645,6 +2645,10 @@ H5MF_settle_raw_data_fsm(H5F_t *f, hbool_t *fsm_settled)
HDassert(f->shared);
HDassert(fsm_settled);
+ /* Initialize structs */
+ HDmemset(&fsinfo, 0, sizeof(fsinfo));
+ HDmemset(&fs_stat, 0, sizeof(fs_stat));
+
/*
* Only need to settle things if we are persisting free space and
* the private property in f->shared->null_fsm_addr is not enabled.