summaryrefslogtreecommitdiffstats
path: root/src/H5Pfapl.c
diff options
context:
space:
mode:
authormyang6 <myang6@hdfgroup.org>2021-10-15 18:29:19 (GMT)
committermyang6 <myang6@hdfgroup.org>2021-10-15 18:29:19 (GMT)
commit89cde3e0009bf2e97319ba3f36c100c97b6208e1 (patch)
tree8896cfb98ced41d3bfe87a1bf627ccab2a879a5e /src/H5Pfapl.c
parenta45b73e4275b26505d8b659d1d807a654bb60df7 (diff)
downloadhdf5-89cde3e0009bf2e97319ba3f36c100c97b6208e1.zip
hdf5-89cde3e0009bf2e97319ba3f36c100c97b6208e1.tar.gz
hdf5-89cde3e0009bf2e97319ba3f36c100c97b6208e1.tar.bz2
Test to just write a log file for H5Fopen. Add a testing routine vfd_swmr_log_writer.c.
Diffstat (limited to 'src/H5Pfapl.c')
-rw-r--r--src/H5Pfapl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/H5Pfapl.c b/src/H5Pfapl.c
index d20503f..35bb09e 100644
--- a/src/H5Pfapl.c
+++ b/src/H5Pfapl.c
@@ -5710,6 +5710,10 @@ H5Pset_vfd_swmr_config(hid_t plist_id, H5F_vfd_swmr_config_t *config_ptr)
else if (name_len > H5F__MAX_VFD_SWMR_FILE_NAME_LEN)
HGOTO_ERROR(H5E_PLIST, H5E_BADVALUE, FAIL, "md_file_path is too long")
+ name_len = HDstrlen(config_ptr->log_file_path);
+ if(name_len >H5F__MAX_VFD_SWMR_FILE_NAME_LEN)
+ HGOTO_ERROR(H5E_PLIST, H5E_BADVALUE, FAIL, "log_file_path is too long")
+
/* Set the modified config */
if (H5P_set(plist, H5F_ACS_VFD_SWMR_CONFIG_NAME, config_ptr) < 0)
HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set metadata cache initial config")