diff options
author | Dana Robinson <43805+derobins@users.noreply.github.com> | 2021-06-18 13:07:35 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-18 13:07:35 (GMT) |
commit | 79c2a900d3d02fd43991ebfabcce651fae8ff748 (patch) | |
tree | 6d344f8272473a0139129b7c2d315673f1dd9945 /test/vfd_swmr_attrdset_writer.c | |
parent | a00ad2b657b7918d4b11edee893f6701cf50e351 (diff) | |
download | hdf5-79c2a900d3d02fd43991ebfabcce651fae8ff748.zip hdf5-79c2a900d3d02fd43991ebfabcce651fae8ff748.tar.gz hdf5-79c2a900d3d02fd43991ebfabcce651fae8ff748.tar.bz2 |
VFD SWMR: Minor fixes (#771)
* Fixes missing C99 format specifiers in page_buffer test
* Warning and other misc fixes in VFD SWMR accept. tests
* Committing clang-format changes
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'test/vfd_swmr_attrdset_writer.c')
-rw-r--r-- | test/vfd_swmr_attrdset_writer.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/test/vfd_swmr_attrdset_writer.c b/test/vfd_swmr_attrdset_writer.c index 3336e88..48dfe9d 100644 --- a/test/vfd_swmr_attrdset_writer.c +++ b/test/vfd_swmr_attrdset_writer.c @@ -1097,7 +1097,8 @@ modify_attr(const state_t *s, hid_t did, unsigned int which) TEST_ERROR; } - if ((val = HDmalloc(sizeof("9999999999"))) == NULL) { + /* Needs to fit "%u %c", below */ + if ((val = HDmalloc(10 + 3)) == NULL) { HDprintf("HDmalloc failed\n"); TEST_ERROR; } @@ -1319,8 +1320,9 @@ verify_add_or_modify_attr(unsigned action, hid_t did, char *attr_name, unsigned char vl_which[sizeof("attr-9999999999")]; char * read_vl_which = NULL; bool is_vl = false; - hid_t aid, atid; - bool ret; + hid_t aid = H5I_INVALID_HID; + hid_t atid = H5I_INVALID_HID; + bool ret = FALSE; HDassert(did != badhid); HDassert(action == ADD_ATTR || action == MODIFY_ATTR); @@ -1761,9 +1763,10 @@ error: int main(int argc, char **argv) { - hid_t fapl, fcpl; + hid_t fapl = H5I_INVALID_HID; + hid_t fcpl = H5I_INVALID_HID; unsigned step; - bool writer; + bool writer = FALSE; state_t s; const char * personality; H5F_vfd_swmr_config_t config; |