Skip to content

Commit

Permalink
Require FAPL in H5Pset_vol()
Browse files Browse the repository at this point in the history
  • Loading branch information
mattjala committed Dec 10, 2024
1 parent c781fa1 commit f9c2b8d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions release_docs/RELEASE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,12 @@ New Features
Modifying default property lists was never fully supported and could produce
inconsistent and unexpected behavior.

- H5Pset_vol() now fails when used on a non-file-access property list

Similar to the above. Setting the connector on a non-FAPL had no effect on
library behavior, and the connector ID and information could not be read back
from that plist later.

Parallel Library:
-----------------
-
Expand Down
2 changes: 1 addition & 1 deletion src/H5Pfapl.c
Original file line number Diff line number Diff line change
Expand Up @@ -5829,7 +5829,7 @@ H5Pset_vol(hid_t plist_id, hid_t new_vol_id, const void *new_vol_info)
FUNC_ENTER_API(FAIL)

/* Check arguments */
if (NULL == (plist = (H5P_genplist_t *)H5I_object_verify(plist_id, H5I_GENPROP_LST)))
if (NULL == (plist = (H5P_genplist_t *)H5P_object_verify(plist_id, H5P_FILE_ACCESS, false)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a property list");
if (H5P_is_default_plist(plist_id))
HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "can't change VOL connector on a default property list");
Expand Down

0 comments on commit f9c2b8d

Please sign in to comment.