aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetIOHDF5/src/Output.cc
diff options
context:
space:
mode:
Diffstat (limited to 'Carpet/CarpetIOHDF5/src/Output.cc')
-rw-r--r--Carpet/CarpetIOHDF5/src/Output.cc10
1 files changed, 7 insertions, 3 deletions
diff --git a/Carpet/CarpetIOHDF5/src/Output.cc b/Carpet/CarpetIOHDF5/src/Output.cc
index 3562f2a4e..2268ce2a8 100644
--- a/Carpet/CarpetIOHDF5/src/Output.cc
+++ b/Carpet/CarpetIOHDF5/src/Output.cc
@@ -189,10 +189,14 @@ int WriteVarUnchunked (const cGH* const cctkGH,
}
} else {
hsize_t overlapshape[dim];
-#if (H5_VERS_MAJOR == 1 && H5_VERS_MINOR == 6 && H5_VERS_RELEASE >= 4)
- hsize_t overlaporigin[dim];
-#else
+
+ // before HDF5-1.6.4 the H5Sselect_hyperslab() function expected
+ // the 'start' argument to be of type 'hssize_t'
+#if (H5_VERS_MAJOR == 1 && \
+ (H5_VERS_MINOR < 6 || (H5_VERS_MINOR == 6 && H5_VERS_RELEASE < 4)))
hssize_t overlaporigin[dim];
+#else
+ hsize_t overlaporigin[dim];
#endif
for (int d = 0; d < group.dim; ++d) {
overlaporigin[group.dim-1-d] =