summaryrefslogtreecommitdiffstats
path: root/src/H5Rint.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2018-10-25 04:52:47 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2018-10-25 04:52:47 (GMT)
commit0df6e44a6e68da1614cf80b50ed7b208edaa5df7 (patch)
treef734083b478d38e09b0aecb8e8f3db838cf0b785 /src/H5Rint.c
parent1e8ef703cdc057211b3587be776a6e9f62e8f76f (diff)
downloadhdf5-0df6e44a6e68da1614cf80b50ed7b208edaa5df7.zip
hdf5-0df6e44a6e68da1614cf80b50ed7b208edaa5df7.tar.gz
hdf5-0df6e44a6e68da1614cf80b50ed7b208edaa5df7.tar.bz2
Squashed commit of private branch changes to support stackable VOL plugins.
modified: test/dsets.c
Diffstat (limited to 'src/H5Rint.c')
-rw-r--r--src/H5Rint.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/src/H5Rint.c b/src/H5Rint.c
index 52a4ee1..7142d54 100644
--- a/src/H5Rint.c
+++ b/src/H5Rint.c
@@ -692,9 +692,9 @@ done:
REVISION LOG
--------------------------------------------------------------------------*/
ssize_t
-H5R__get_name(H5F_t *f, H5R_type_t ref_type, const void *_ref, char *name, size_t size)
+H5R__get_name(H5F_t *f, H5R_type_t ref_type, const void *_ref,
+ char *name, size_t size)
{
- hid_t file_id = H5I_INVALID_HID; /* ID for file that the reference is in */
H5O_loc_t oloc; /* Object location describing object for reference */
ssize_t ret_value = -1; /* Return value */
@@ -747,19 +747,11 @@ H5R__get_name(H5F_t *f, H5R_type_t ref_type, const void *_ref, char *name, size_
HGOTO_ERROR(H5E_REFERENCE, H5E_UNSUPPORTED, (-1), "internal error (unknown reference type)")
} /* end switch */
- /* Retrieve file ID for name search */
- if ((file_id = H5F_get_id(f, FALSE)) < 0)
- HGOTO_ERROR(H5E_ATOM, H5E_CANTGET, (-1), "can't get file ID")
-
/* Get name, length, etc. */
- if ((ret_value = H5G_get_name_by_addr(file_id, &oloc, name, size)) < 0)
+ if ((ret_value = H5G_get_name_by_addr(f, &oloc, name, size)) < 0)
HGOTO_ERROR(H5E_REFERENCE, H5E_CANTGET, (-1), "can't determine name")
done:
- /* Close file ID used for search */
- if (file_id > 0 && H5I_dec_ref(file_id) < 0)
- HDONE_ERROR(H5E_REFERENCE, H5E_CANTDEC, (-1), "can't decrement ref count of temp ID")
-
FUNC_LEAVE_NOAPI(ret_value)
} /* end H5R__get_name() */