Unverified Commit c2d9c6d0 authored by Atkins, Charles Vernon's avatar Atkins, Charles Vernon Committed by GitHub
Browse files

Merge pull request #3156 from guj/h5version

added check H5_USE_1xx_API to make sure H5 is not using older API.
parents 55dbc88c 522b380b
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -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
@@ -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