diff options
-rw-r--r-- | tools/lib/h5tools_str.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/tools/lib/h5tools_str.c b/tools/lib/h5tools_str.c index 94b0ff2..6aab146 100644 --- a/tools/lib/h5tools_str.c +++ b/tools/lib/h5tools_str.c @@ -468,16 +468,24 @@ h5tools_str_dump_space_slabs(h5tools_str_t *str, hid_t rspace, /* Count coordinates */ h5tools_str_append(str, "%s ", COUNT); - for (j = 0; j < ndims; j++) - h5tools_str_append(str, "%s" HSIZE_T_FORMAT, j ? "," : "(", count[j]); + for (j = 0; j < ndims; j++) { + if(count[j] == H5S_UNLIMITED) + h5tools_str_append(str, "%s%s", j ? "," : "(","H5S_UNLIMITED"); + else + h5tools_str_append(str, "%s" HSIZE_T_FORMAT, j ? "," : "(", count[j]); + } h5tools_str_append(str, ");"); h5tools_str_append(str, "%s", "\n"); h5tools_str_indent(str, info, ctx); /* Block coordinates */ h5tools_str_append(str, "%s ", BLOCK); - for (j = 0; j < ndims; j++) - h5tools_str_append(str, "%s" HSIZE_T_FORMAT, j ? "," : "(", block[j]); + for (j = 0; j < ndims; j++) { + if(block[j] == H5S_UNLIMITED) + h5tools_str_append(str, "%s%s", j ? "," : "(","H5S_UNLIMITED"); + else + h5tools_str_append(str, "%s" HSIZE_T_FORMAT, j ? "," : "(", block[j]); + } h5tools_str_append(str, ");"); h5tools_str_append(str, "%s", "\n"); h5tools_str_indent(str, info, ctx); |