diff options
Diffstat (limited to 'tools/lib/h5tools_str.c')
-rw-r--r-- | tools/lib/h5tools_str.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/tools/lib/h5tools_str.c b/tools/lib/h5tools_str.c index a12ea7f..3a139c3 100644 --- a/tools/lib/h5tools_str.c +++ b/tools/lib/h5tools_str.c @@ -1090,7 +1090,7 @@ h5tools_str_sprint(h5tools_str_t *str, const h5tool_format_t *info, hid_t contai else { if(nsize == H5R_DSET_REG_REF_BUF_SIZE) { /* if (H5Tequal(type, H5T_STD_REF_DSETREG)) */ - H5TOOLS_DEBUG("ref_type is H5R_DATASET_REGION1"); + H5TOOLS_DEBUG("H5T_REFERENCE:H5T_STD_REF_DSETREG"); h5tools_str_append(str, H5_TOOLS_DATASET); h5tools_str_sprint_reference(str, container, vp); } @@ -1102,22 +1102,22 @@ h5tools_str_sprint(h5tools_str_t *str, const h5tool_format_t *info, hid_t contai H5O_info_t oi; const char *path; - H5TOOLS_DEBUG("ref_type is H5R_OBJECT"); + H5TOOLS_DEBUG("H5T_REFERENCE:H5T_STD_REF_OBJ"); obj = H5Rdereference2(container, H5P_DEFAULT, H5R_OBJECT, vp); H5Oget_info2(obj, &oi, H5O_INFO_BASIC); /* Print object type and close object */ switch(oi.type) { case H5O_TYPE_GROUP: - h5tools_str_append(str, H5_TOOLS_GROUP); + h5tools_str_append(str, "%u-%s", (unsigned) oi.type, H5_TOOLS_GROUP); break; case H5O_TYPE_DATASET: - h5tools_str_append(str, H5_TOOLS_DATASET); + h5tools_str_append(str, "%u-%s", (unsigned) oi.type, H5_TOOLS_DATASET); break; case H5O_TYPE_NAMED_DATATYPE: - h5tools_str_append(str, H5_TOOLS_DATATYPE); + h5tools_str_append(str, "%u-%s", (unsigned) oi.type, H5_TOOLS_DATATYPE); break; case H5O_TYPE_UNKNOWN: @@ -1128,6 +1128,8 @@ h5tools_str_sprint(h5tools_str_t *str, const h5tool_format_t *info, hid_t contai } /* end switch */ H5Oclose(obj); + h5tools_str_sprint_reference(str, container, vp); + /* Print OID */ if(info->obj_hidefileno) h5tools_str_append(str, info->obj_format, oi.addr); @@ -1304,25 +1306,23 @@ h5tools_str_sprint_reference(h5tools_str_t *str, hid_t container, void *vp) H5TOOLS_START_DEBUG(""); - h5tools_str_append(str, " \""); obj = H5Rdereference2(container, H5P_DEFAULT, H5R_DATASET_REGION, vp); if(obj >= 0) { region = H5Rget_region(container, H5R_DATASET_REGION, vp); if(region >= 0) { H5Rget_name(obj, H5R_DATASET_REGION, vp, (char*) ref_name, 1024); - + h5tools_str_append(str, " \""); h5tools_str_append(str, "%s", ref_name); + h5tools_str_append(str, "\""); H5Sclose(region); } /* end if (region >= 0) */ H5Dclose(obj); } /* end if (obj >= 0) */ - h5tools_str_append(str, "\""); H5TOOLS_ENDDEBUG(""); } - /*------------------------------------------------------------------------- * Function: h5tools_escape * |