summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/H5A.c48
-rw-r--r--src/H5G.c10
-rw-r--r--src/H5O.c25
-rw-r--r--src/H5R.c5
-rw-r--r--src/H5Rdeprec.c5
-rw-r--r--src/H5VL.c61
-rw-r--r--src/H5VLnative.c73
-rw-r--r--src/H5VLprivate.h1
-rw-r--r--src/H5VLpublic.h11
9 files changed, 167 insertions, 72 deletions
diff --git a/src/H5A.c b/src/H5A.c
index 3017e7f..2c361dc 100644
--- a/src/H5A.c
+++ b/src/H5A.c
@@ -338,8 +338,9 @@ H5Acreate_by_name(hid_t loc_id, const char *obj_name, const char *attr_name,
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* H5Acreate_by_name() */
@@ -611,8 +612,9 @@ H5Aopen_by_name(hid_t loc_id, const char *obj_name, const char *attr_name,
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* H5Aopen_by_name() */
@@ -1694,8 +1696,9 @@ done:
HDONE_ERROR(H5E_ATTR, H5E_CANTFREE, FAIL, "can't close attribute")
if(NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Aget_info_by_name() */
@@ -1868,7 +1871,6 @@ herr_t
H5Arename_by_name(hid_t loc_id, const char *obj_name, const char *old_attr_name,
const char *new_attr_name, hid_t lapl_id)
{
- void *location = NULL;
herr_t ret_value = SUCCEED; /* Return value */
FUNC_ENTER_API(FAIL)
@@ -1892,6 +1894,8 @@ H5Arename_by_name(hid_t loc_id, const char *obj_name, const char *old_attr_name,
/* Avoid thrashing things if the names are the same */
if(HDstrcmp(old_attr_name, new_attr_name)) {
+ void *location = NULL;
+
/* Get the token for the Object location through the VOL */
if(H5VL_object_lookup(loc_id, H5VL_OBJECT_LOOKUP_BY_NAME, H5_REQUEST_NULL, &location, obj_name, lapl_id) < 0)
HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to locate object")
@@ -1899,13 +1903,15 @@ H5Arename_by_name(hid_t loc_id, const char *obj_name, const char *old_attr_name,
/* get the attribute info through the VOL */
if(H5VL_object_generic(loc_id, H5VL_ATTR_RENAME, H5_REQUEST_NULL, location, old_attr_name, new_attr_name) < 0)
HGOTO_ERROR(H5E_INTERNAL, H5E_CANTGET, FAIL, "unable to get attribute info")
+
+ if(NULL != location) {
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
+ }
} /* end if */
done:
- if(NULL != location) {
- free (location);
- location = NULL;
- }
FUNC_LEAVE_API(ret_value)
} /* H5Arename_by_name() */
@@ -2091,6 +2097,11 @@ done:
HDONE_ERROR(H5E_ATTR, H5E_CANTDEC, FAIL, "unable to close temporary object")
} /* end if */
+ if(NULL != location) {
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
+ }
FUNC_LEAVE_API(ret_value)
} /* H5Aiterate_by_name() */
@@ -2181,8 +2192,9 @@ H5Adelete_by_name(hid_t loc_id, const char *obj_name, const char *attr_name,
done:
if(NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* H5Adelete_by_name() */
@@ -2247,8 +2259,9 @@ H5Adelete_by_idx(hid_t loc_id, const char *obj_name, H5_index_t idx_type,
done:
if(NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* H5Adelete_by_idx() */
@@ -2634,8 +2647,9 @@ H5Aexists_by_name(hid_t loc_id, const char *obj_name, const char *attr_name,
done:
if(NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* H5Aexists_by_name() */
diff --git a/src/H5G.c b/src/H5G.c
index 0e91191..e9211ec 100644
--- a/src/H5G.c
+++ b/src/H5G.c
@@ -536,8 +536,9 @@ H5Gget_info_by_name(hid_t loc_id, const char *name, H5G_info_t *grp_info,
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Gget_info_by_name() */
@@ -595,8 +596,9 @@ H5Gget_info_by_idx(hid_t loc_id, const char *group_name, H5_index_t idx_type,
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Gget_info_by_idx() */
diff --git a/src/H5O.c b/src/H5O.c
index f054232..b6e1447 100644
--- a/src/H5O.c
+++ b/src/H5O.c
@@ -250,8 +250,9 @@ H5Oopen(hid_t loc_id, const char *name, hid_t lapl_id)
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
@@ -315,8 +316,9 @@ H5Oopen_by_idx(hid_t loc_id, const char *group_name, H5_index_t idx_type,
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Oopen_by_idx() */
@@ -377,8 +379,9 @@ H5Oopen_by_addr(hid_t loc_id, haddr_t addr)
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Oopen_by_addr() */
@@ -650,8 +653,9 @@ H5Oget_info_by_name(hid_t loc_id, const char *name, H5O_info_t *oinfo, hid_t lap
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Oget_info_by_name() */
@@ -709,8 +713,9 @@ H5Oget_info_by_idx(hid_t loc_id, const char *group_name, H5_index_t idx_type,
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Oget_info_by_idx() */
diff --git a/src/H5R.c b/src/H5R.c
index 30b44ac..4306f3b 100644
--- a/src/H5R.c
+++ b/src/H5R.c
@@ -536,8 +536,9 @@ H5Rdereference2(hid_t obj_id, hid_t oapl_id, H5R_type_t ref_type, const void *_r
done:
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (obj_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
FUNC_LEAVE_API(ret_value)
} /* end H5Rdereference2() */
diff --git a/src/H5Rdeprec.c b/src/H5Rdeprec.c
index b3838f1..5fb6813 100644
--- a/src/H5Rdeprec.c
+++ b/src/H5Rdeprec.c
@@ -204,6 +204,11 @@ H5Rdereference1(hid_t obj_id, H5R_type_t ref_type, const void *_ref)
HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to open object")
done:
+ if (NULL != location) {
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (obj_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
+ }
FUNC_LEAVE_API(ret_value)
} /* end H5Rdereference1() */
diff --git a/src/H5VL.c b/src/H5VL.c
index c45ebb9..6624d2b 100644
--- a/src/H5VL.c
+++ b/src/H5VL.c
@@ -991,6 +991,12 @@ H5VL_datatype_open(hid_t loc_id, const char *name, hid_t tapl_id, hid_t req)
/* Open the object through the VOL */
if((ret_value = H5VL_object_open_by_loc(loc_id, location, tapl_id, req)) < 0)
HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to open object")
+
+ if (NULL != location) {
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
+ }
}
else {
/* call the corresponding VOL open callback */
@@ -1167,6 +1173,12 @@ H5VL_dataset_open(hid_t loc_id, const char *name, hid_t dapl_id, hid_t req)
/* Open the object through the VOL */
if((ret_value = H5VL_object_open_by_loc(loc_id, location, dapl_id, req)) < 0)
HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to open object")
+
+ if (NULL != location) {
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
+ }
}
else {
/* call the corresponding VOL open callback */
@@ -1812,8 +1824,9 @@ H5VL_group_open(hid_t loc_id, const char *name, hid_t gapl_id, hid_t req)
HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to open object")
if (NULL != location) {
- free (location);
- location = NULL;
+ /* free the location token through the VOL */
+ if(H5VL_object_free_loc (loc_id, location, H5_REQUEST_NULL) < 0)
+ HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "unable to free location token")
}
}
else {
@@ -2316,6 +2329,50 @@ done:
/*-------------------------------------------------------------------------
+ * Function: H5VL_object_free_loc
+ *
+ * Purpose: Free the location token
+ *
+ * Return: Success: non negative
+ * Failure: negative
+ *
+ * Programmer: Mohamad Chaarawi
+ * May, 2012
+ *
+ *-------------------------------------------------------------------------
+ */
+herr_t
+H5VL_object_free_loc(hid_t loc_id, void *location, hid_t req)
+{
+ H5VL_id_wrapper_t *id_wrapper; /* user id structure */
+ H5I_type_t id_type;
+ herr_t ret_value = SUCCEED;
+
+ FUNC_ENTER_NOAPI(FAIL)
+
+ id_type = H5I_get_type(loc_id);
+ /* Check id */
+ 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)
+ HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a user ID")
+
+ /* unwrap the ID struct */
+ if(NULL == (id_wrapper = (H5VL_id_wrapper_t *)H5I_object(loc_id)))
+ HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "invalid user identifier")
+
+ if(NULL == id_wrapper->vol_plugin->object_cls.free_loc)
+ HGOTO_ERROR(H5E_VOL, H5E_UNSUPPORTED, FAIL, "vol plugin has no `object free_loc' method")
+
+ if((ret_value = (id_wrapper->vol_plugin->object_cls.free_loc)(location, req)) < 0)
+ HGOTO_ERROR(H5E_VOL, H5E_CANTRELEASE, FAIL, "freeing location token of object location failed")
+
+done:
+ FUNC_LEAVE_NOAPI(ret_value)
+} /* end H5VL_object_free_loc() */
+
+
+/*-------------------------------------------------------------------------
* Function: H5VL_object_get
*
* Purpose: Get specific information about the object through the VOL
diff --git a/src/H5VLnative.c b/src/H5VLnative.c
index edd8d1c..be3d8a3 100644
--- a/src/H5VLnative.c
+++ b/src/H5VLnative.c
@@ -109,6 +109,7 @@ static hid_t H5VL_native_object_open(hid_t loc_id, void *location, hid_t lapl_id
static herr_t H5VL_native_object_copy(hid_t src_loc_id, const char *src_name, hid_t dst_loc_id,
const char *dst_name, hid_t ocpypl_id, hid_t lcpl_id, hid_t req);
static herr_t H5VL_native_object_lookup(hid_t loc_id, H5VL_object_lookup_t lookup_type, hid_t req, va_list arguments);
+static herr_t H5VL_native_object_free_loc(void *location, hid_t req);
static herr_t H5VL_native_object_get(hid_t id, H5VL_object_get_t get_type, hid_t req, va_list arguments);
static herr_t H5VL_native_object_generic(hid_t id, H5VL_object_generic_t generic_type, hid_t req, va_list arguments);
static herr_t H5VL_native_object_close(hid_t object_id, hid_t req);
@@ -164,6 +165,7 @@ H5VL_class_t H5VL_native_g = {
H5VL_native_object_open, /* open */
H5VL_native_object_copy, /* copy */
H5VL_native_object_lookup, /* lookup */
+ H5VL_native_object_free_loc, /* free location */
H5VL_native_object_get, /* get */
H5VL_native_object_generic, /* generic */
H5VL_native_object_close /* close */
@@ -337,9 +339,6 @@ H5VL_native_attr_create(hid_t loc_id, const char *attr_name, hid_t acpl_id, hid_
/* Go do the real work for attaching the attribute to the dataset */
if((ret_value = H5A_create(obj_loc, attr_name, type, space, acpl_id, H5AC_dxpl_id)) < 0)
HGOTO_ERROR(H5E_ATTR, H5E_CANTINIT, FAIL, "unable to create attribute")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
}
done:
@@ -381,9 +380,6 @@ H5VL_native_attr_open(hid_t loc_id, void *location, const char *attr_name, hid_t
/* Read in attribute from object header */
if(NULL == (attr = H5O_attr_open_by_name(obj_loc->oloc, attr_name, H5AC_ind_dxpl_id)))
HGOTO_ERROR(H5E_ATTR, H5E_CANTINIT, FAIL, "unable to load attribute info from object header")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
}
else { /* H5Aopen */
/* Read in attribute from object header */
@@ -523,9 +519,6 @@ H5VL_native_attr_get(hid_t id, H5VL_attr_get_t get_type, hid_t UNUSED req, va_li
/* Check if the attribute exists */
if((*ret = H5O_attr_exists(obj_loc->oloc, name, H5AC_ind_dxpl_id)) < 0)
HGOTO_ERROR(H5E_ATTR, H5E_CANTGET, FAIL, "unable to determine if attribute exists")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
}
break;
}
@@ -656,9 +649,6 @@ H5VL_native_attr_delete(hid_t loc_id, void *location, const char *attr_name, hid
/* Delete the attribute from the location */
if(H5O_attr_remove(obj_loc->oloc, attr_name, H5AC_dxpl_id) < 0)
HGOTO_ERROR(H5E_ATTR, H5E_CANTDELETE, FAIL, "unable to delete attribute")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
}
done:
FUNC_LEAVE_NOAPI(ret_value)
@@ -1991,9 +1981,6 @@ H5VL_native_group_get(hid_t obj_id, H5VL_group_get_t get_type, hid_t UNUSED req,
/* Retrieve the group's information */
if(H5G__obj_info(obj_loc->oloc, grp_info, H5AC_ind_dxpl_id) < 0)
HGOTO_ERROR(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve group info")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
}
break;
}
@@ -2386,10 +2373,6 @@ H5VL_native_object_open(hid_t loc_id, void *location, hid_t lapl_id, hid_t UNUSE
HGOTO_ERROR(H5E_SYM, H5E_CANTOPENOBJ, FAIL, "unable to open object")
done:
- if(ret_value < 0)
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
-
FUNC_LEAVE_NOAPI(ret_value)
} /* end H5VL_native_object_open() */
@@ -2570,6 +2553,45 @@ done:
/*-------------------------------------------------------------------------
+ * Function: H5VL_native_object_free_loc
+ *
+ * Purpose: Free the location token
+ *
+ * Return: Success: non negative
+ * Failure: negative
+ *
+ * Programmer: Mohamad Chaarawi
+ * May, 2012
+ *
+ *-------------------------------------------------------------------------
+ */
+static herr_t
+H5VL_native_object_free_loc(void *location, hid_t req)
+{
+ H5G_loc_t *obj_loc = (H5G_loc_t *)location;
+ herr_t ret_value = SUCCEED; /* Return value */
+
+ FUNC_ENTER_NOAPI_NOINIT
+
+ if(H5G_loc_free(obj_loc) < 0)
+ HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
+
+ if (NULL != obj_loc->oloc) {
+ H5MM_free(obj_loc->oloc);
+ }
+ if (NULL != obj_loc->path) {
+ H5MM_free(obj_loc->path);
+ }
+ if (NULL != obj_loc) {
+ H5MM_free(obj_loc);
+ }
+
+done:
+ FUNC_LEAVE_NOAPI(ret_value)
+} /* end H5VL_native_object_free_loc() */
+
+
+/*-------------------------------------------------------------------------
* Function: H5VL_native_object_generic
*
* Purpose: Perform a plugin specific operation for an objectibute
@@ -2602,10 +2624,6 @@ H5VL_native_object_generic(hid_t loc_id, H5VL_object_generic_t generic_type, hid
/* Delete the attribute from the location */
if(H5O_attr_remove_by_idx(obj_loc->oloc, idx_type, order, n, H5AC_dxpl_id) < 0)
HGOTO_ERROR(H5E_ATTR, H5E_CANTDELETE, FAIL, "unable to delete attribute")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
-
break;
}
/* H5Aopen_by_idx */
@@ -2654,9 +2672,6 @@ H5VL_native_object_generic(hid_t loc_id, H5VL_object_generic_t generic_type, hid
/* Call attribute rename routine */
if(H5O_attr_rename(obj_loc->oloc, H5AC_dxpl_id, old_name, new_name) < 0)
HGOTO_ERROR(H5E_ATTR, H5E_CANTRENAME, FAIL, "can't rename attribute")
-
- if(H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
}
break;
}
@@ -2771,16 +2786,10 @@ H5VL_native_object_get(hid_t id, H5VL_object_get_t get_type, hid_t UNUSED req, v
if(NULL == obj_loc) {
obj_loc = &loc;
}
- else {
- loc_set = TRUE;
- }
/* Retrieve the object's information */
if(H5O_get_info(obj_loc->oloc, H5AC_ind_dxpl_id, TRUE, obj_info) < 0)
HGOTO_ERROR(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve object info")
-
- if(loc_set && H5G_loc_free(obj_loc) < 0)
- HDONE_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't free location")
break;
}
/* H5Oget_comment / H5Oget_comment_by_name */
diff --git a/src/H5VLprivate.h b/src/H5VLprivate.h
index da977a7..3e682f6 100644
--- a/src/H5VLprivate.h
+++ b/src/H5VLprivate.h
@@ -102,6 +102,7 @@ H5_DLL herr_t H5VL_object_copy(hid_t src_loc_id, const char *src_name, hid_t dst
H5_DLL herr_t H5VL_object_get(hid_t uid, H5VL_object_get_t get_type, hid_t req, ...);
H5_DLL herr_t H5VL_object_generic(hid_t id, H5VL_object_generic_t generic_type, hid_t req, ...);
H5_DLL herr_t H5VL_object_lookup(hid_t uid, H5VL_object_lookup_t lookup_type, hid_t req, ...);
+H5_DLL herr_t H5VL_object_free_loc(hid_t loc_id, void *location, hid_t req);
H5_DLL herr_t H5VL_object_close(hid_t uid, hid_t req);
H5_DLL herr_t H5VL_fapl_open(struct H5P_genplist_t *plist, H5VL_class_t *vol_cls);
diff --git a/src/H5VLpublic.h b/src/H5VLpublic.h
index baf0629..44f3e8f 100644
--- a/src/H5VLpublic.h
+++ b/src/H5VLpublic.h
@@ -95,11 +95,11 @@ typedef enum H5VL_link_get_t {
/* types for all object general operations */
typedef enum H5VL_object_generic_t {
H5VL_ATTR_DELETE_BY_IDX = 0, /* H5Adelete_by_idx */
- H5VL_ATTR_OPEN_BY_IDX = 2, /* H5Aopen_by_idx */
- H5VL_ATTR_RENAME = 3, /* H5Arename */
- H5VL_OBJECT_CHANGE_REF_COUNT = 4, /* H5Oincr/decr_refcount */
- H5VL_OBJECT_SET_COMMENT = 6, /* H5Oset_comment(_by_name) */
- H5VL_REF_CREATE = 7 /* H5Rcreate */
+ H5VL_ATTR_OPEN_BY_IDX = 1, /* H5Aopen_by_idx */
+ H5VL_ATTR_RENAME = 2, /* H5Arename */
+ H5VL_OBJECT_CHANGE_REF_COUNT = 3, /* H5Oincr/decr_refcount */
+ H5VL_OBJECT_SET_COMMENT = 4, /* H5Oset_comment(_by_name) */
+ H5VL_REF_CREATE = 5 /* H5Rcreate */
} H5VL_object_generic_t;
/* types for all object get API routines */
@@ -190,6 +190,7 @@ typedef struct H5VL_object_class_t {
herr_t (*copy) (hid_t src_loc_id, const char *src_name, hid_t dst_loc_id, const char *dst_name,
hid_t ocpypl_id, hid_t lcpl_id, hid_t req);
herr_t (*lookup)(hid_t loc_id, H5VL_object_lookup_t lookup_type, hid_t req, va_list arguments);
+ herr_t (*free_loc)(void *location, hid_t req);
herr_t (*get) (hid_t loc_id, H5VL_object_get_t get_type, hid_t req, va_list arguments);
herr_t (*generic)(hid_t id, H5VL_object_generic_t generic_type, hid_t req, va_list arguments);
herr_t (*close) (hid_t obj_id, hid_t req);