#================================================================================================== # From 4c70103d215bb70d4820cd4569321361d0baade7 Mon Sep 17 00:00:00 2001 # From: Mark Harfouche # Date: Tue, 28 Sep 2021 09:45:08 -0400 # Subject: [PATCH] Add compatibility for HDF5 1.12 #================================================================================================== --- src/impex/hdf5impex.cxx +++ src/impex/hdf5impex.cxx @@ -190,7 +190,11 @@ H5O_type_t HDF5_get_type(hid_t loc_id, const char* name) { // get information about object H5O_info_t infobuf; +#if H5Oget_info_by_name_vers >= 3 + H5Oget_info_by_name(loc_id, name, &infobuf, H5O_INFO_BASIC, H5P_DEFAULT); +#else H5Oget_info_by_name(loc_id, name, &infobuf, H5P_DEFAULT); +#endif return infobuf.type; }