From 113632b14246c6a757184e24595746329273edbb Mon Sep 17 00:00:00 2001 From: Thomas Helfer Date: Mon, 12 Feb 2024 14:39:44 +0100 Subject: [PATCH] Fix Issue #3 --- src/HDF5.cxx | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/HDF5.cxx b/src/HDF5.cxx index b762e06..eb94c7f 100644 --- a/src/HDF5.cxx +++ b/src/HDF5.cxx @@ -215,8 +215,18 @@ namespace madnex { return false; } H5O_info_t infobuf; +#ifdef H5Oget_info_by_name_vers +#if H5Oget_info_by_name_vers >=3 + auto status = H5Oget_info_by_name(g.getId(), p.c_str(), &infobuf, + H5O_INFO_ALL, H5P_DEFAULT); +#else auto status = H5Oget_info_by_name(g.getId(), p.c_str(), &infobuf, H5P_DEFAULT); +#endif +#else + auto status = + H5Oget_info_by_name(g.getId(), p.c_str(), &infobuf, H5P_DEFAULT); +#endif return (status >= 0) && (infobuf.type == H5O_TYPE_GROUP); }