Skip to content

Commit

Permalink
Merge pull request #3156 from guj/h5version
Browse files Browse the repository at this point in the history
added check H5_USE_1xx_API to make sure H5 is not using older API.
  • Loading branch information
Chuck Atkins authored Apr 5, 2022
2 parents 55dbc88 + 522b380 commit c2d9c6d
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions source/adios2/toolkit/interop/hdf5/HDF5Common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1629,7 +1629,11 @@ void HDF5Common::ReadAttrToIO(core::IO &io)
H5O_info_t oinfo;

#if H5_VERSION_GE(1, 11, 0)
#if (defined H5_USE_16_API || defined H5_USE_18_API)
herr_t ret = H5Oget_info(m_FileId, &oinfo);
#else
herr_t ret = H5Oget_info(m_FileId, &oinfo, H5O_INFO_ALL);
#endif
#else
herr_t ret = H5Oget_info(m_FileId, &oinfo);
#endif
Expand Down Expand Up @@ -1685,7 +1689,11 @@ void HDF5Common::ReadNativeAttrToIO(core::IO &io, hid_t datasetId,

H5O_info_t oinfo;
#if H5_VERSION_GE(1, 11, 0)
#if (defined H5_USE_16_API || defined H5_USE_18_API)
herr_t ret = H5Oget_info(datasetId, &oinfo);
#else
herr_t ret = H5Oget_info(datasetId, &oinfo, H5O_INFO_ALL);
#endif
#else
herr_t ret = H5Oget_info(datasetId, &oinfo);
#endif
Expand Down

0 comments on commit c2d9c6d

Please sign in to comment.