summaryrefslogtreecommitdiffstats
path: root/src/H5Gtest.c
diff options
context:
space:
mode:
authorMohamad Chaarawi <chaarawi@hdfgroup.org>2012-04-09 22:17:52 (GMT)
committerMohamad Chaarawi <chaarawi@hdfgroup.org>2012-04-09 22:17:52 (GMT)
commit0dbc51127e4b4bc2f3ada3b0958cc9dc2607c541 (patch)
tree6c6a2d732b70389e350f4f01b3920211e186de36 /src/H5Gtest.c
parent7d7842302b1dcf0da0067b30c49da59b8f766cb3 (diff)
downloadhdf5-0dbc51127e4b4bc2f3ada3b0958cc9dc2607c541.zip
hdf5-0dbc51127e4b4bc2f3ada3b0958cc9dc2607c541.tar.gz
hdf5-0dbc51127e4b4bc2f3ada3b0958cc9dc2607c541.tar.bz2
[svn-r22271] unwrap the high level ids in several places
add some workarounds for named datatypes in test cases and H5T routines fix some iterate bugs with UD links
Diffstat (limited to 'src/H5Gtest.c')
-rw-r--r--src/H5Gtest.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/H5Gtest.c b/src/H5Gtest.c
index 48aa10b..86730a7 100644
--- a/src/H5Gtest.c
+++ b/src/H5Gtest.c
@@ -36,6 +36,7 @@
#include "H5Gpkg.h" /* Groups */
#include "H5HLprivate.h" /* Local Heaps */
#include "H5Iprivate.h" /* IDs */
+#include "H5VLprivate.h" /* Virtual Object Layer */
/****************/
/* Local Macros */
@@ -514,6 +515,7 @@ H5G__user_path_test(hid_t obj_id, char *user_path, size_t *user_path_len, unsign
{
void *obj_ptr; /* Pointer to object for ID */
H5G_name_t *obj_path; /* Pointer to group hier. path for obj */
+ H5I_type_t id_type;
herr_t ret_value = SUCCEED; /* Return value */
FUNC_ENTER_PACKAGE
@@ -522,6 +524,20 @@ H5G__user_path_test(hid_t obj_id, char *user_path, size_t *user_path_len, unsign
HDassert(user_path_len);
HDassert(obj_hidden);
+ id_type = H5I_get_type(obj_id);
+ /* get the actual OBJ_ID from an upper ID level */
+ /* MSC - this is a workaround to allow the test suite to pass and
+ at some point needs to be removed once all high level operations
+ that needs to go through the VOL actually go through the VOL*/
+ if (H5I_FILE_PUBLIC == id_type || H5I_GROUP_PUBLIC == id_type ||
+ H5I_DATASET_PUBLIC == id_type || H5I_DATATYPE_PUBLIC == id_type ||
+ H5I_ATTR_PUBLIC == id_type) {
+ H5VL_id_wrapper_t *id_wrapper; /* user id structure */
+ if(NULL == (id_wrapper = (H5VL_id_wrapper_t *)H5I_object(obj_id)))
+ HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "invalid user identifier")
+ obj_id = id_wrapper->obj_id;
+ }
+
/* Get pointer to object for ID */
if(NULL == (obj_ptr = H5I_object(obj_id)))
HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "can't get object for ID")