diff options
author | Mohamad Chaarawi <chaarawi@hdfgroup.org> | 2014-07-31 19:26:19 (GMT) |
---|---|---|
committer | Mohamad Chaarawi <chaarawi@hdfgroup.org> | 2014-07-31 19:26:19 (GMT) |
commit | beb6f83cfd696e835970091f730a23db31381455 (patch) | |
tree | 8250eb2f16a6c7efbf7b54ffcfe3e968aa1b278b | |
parent | 33ea1ada248725e4cce6316c503e5c760bcca49c (diff) | |
download | hdf5-beb6f83cfd696e835970091f730a23db31381455.zip hdf5-beb6f83cfd696e835970091f730a23db31381455.tar.gz hdf5-beb6f83cfd696e835970091f730a23db31381455.tar.bz2 |
[svn-r25500] fix HDFFV-8888 - H5Ldelete_by_idx fails on non-existent group name.
tested Jam. minor change.
-rw-r--r-- | src/H5L.c | 2 | ||||
-rw-r--r-- | test/links.c | 6 |
2 files changed, 7 insertions, 1 deletions
@@ -2372,7 +2372,7 @@ H5L_delete_by_idx_cb(H5G_loc_t UNUSED *grp_loc/*in*/, const char UNUSED *name, H5L_trav_gvbi_t *udata = (H5L_trav_gvbi_t *)_udata; /* User data passed in */ herr_t ret_value = SUCCEED; /* Return value */ - FUNC_ENTER_NOAPI_NOINIT_TAG(udata->dxpl_id, obj_loc->oloc->addr, FAIL) + FUNC_ENTER_NOAPI_NOINIT_TAG(udata->dxpl_id, (obj_loc) ? (obj_loc->oloc->addr) : HADDR_UNDEF, FAIL) /* Check if the name of the group resolved to a valid object */ if(obj_loc == NULL) diff --git a/test/links.c b/test/links.c index f1e6daa..09c2d4d 100644 --- a/test/links.c +++ b/test/links.c @@ -11422,6 +11422,12 @@ delete_by_idx(hid_t fapl) } H5E_END_TRY; if(ret >= 0) TEST_ERROR + /* Check for deletion on non-existing group */ + H5E_BEGIN_TRY { + ret = H5Ldelete_by_idx(group_id, "None", idx_type, order, (hsize_t)0, H5P_DEFAULT); + } H5E_END_TRY; + if(ret >= 0) TEST_ERROR + /* Create several links, up to limit of compact form */ for(u = 0; u < max_compact; u++) { hid_t group_id2; /* Group ID */ |