summaryrefslogtreecommitdiffstats
path: root/tools/h5dump
diff options
context:
space:
mode:
authorNeil Fortner <nfortne2@hdfgroup.org>2008-09-21 18:35:43 (GMT)
committerNeil Fortner <nfortne2@hdfgroup.org>2008-09-21 18:35:43 (GMT)
commit6d28e06f30587202147f6ae31b658a5021adf2a0 (patch)
tree0ec105751d2a26f24039870fb6e44b770917e18e /tools/h5dump
parentdcd4c0b04988dbe869a3a479381118844217fa66 (diff)
downloadhdf5-6d28e06f30587202147f6ae31b658a5021adf2a0.zip
hdf5-6d28e06f30587202147f6ae31b658a5021adf2a0.tar.gz
hdf5-6d28e06f30587202147f6ae31b658a5021adf2a0.tar.bz2
[svn-r15668] Purpose: Add feature requested in bug #1282
Description: Adds capability to h5ls to traverse external links when the -r (recursive) option is given. Changes to the way absolute path names are patched in h5trav.c. Changes to the way recursive traversal starting from a non-root group is handled (which also fixes some preexisting issues). Tests added for these cases. Tested: kagiso, smirom, linew (h5committest)
Diffstat (limited to 'tools/h5dump')
-rw-r--r--tools/h5dump/h5dumpgentest.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/tools/h5dump/h5dumpgentest.c b/tools/h5dump/h5dumpgentest.c
index d3e1502..bd3c4de 100644
--- a/tools/h5dump/h5dumpgentest.c
+++ b/tools/h5dump/h5dumpgentest.c
@@ -6198,14 +6198,18 @@ gent_extlinks(void)
/*-------------------------------------------------------------------------
- * create a Group, a Dataset, and a committed Datatype in the target
+ * create Groups, a Dataset, a committed Datatype, and external links in
+ * the target
*-------------------------------------------------------------------------
*/
gid = H5Gcreate2(target_fid, "group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
+ H5Gclose(H5Gcreate2(target_fid, "empty_group", H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT));
sid = H5Screate_simple(1, dims, NULL);
did = H5Dcreate2(gid, "dset", H5T_NATIVE_INT, sid, H5P_DEFAULT, H5P_DEFAULT, H5P_DEFAULT);
H5Dwrite(did, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, buf);
+ H5Lcreate_external(FILE61, "/", gid, "elink_t1", H5P_DEFAULT, H5P_DEFAULT);
+ H5Lcreate_external(FILE61, "/ext_link4", gid, "elink_t2", H5P_DEFAULT, H5P_DEFAULT);
H5Dclose(did);
H5Sclose(sid);
H5Gclose(gid);
@@ -6229,6 +6233,8 @@ gent_extlinks(void)
H5Lcreate_external(FILE62, "group", source_fid, "ext_link1", H5P_DEFAULT, H5P_DEFAULT);
H5Lcreate_external(FILE62, "dset", source_fid, "ext_link2", H5P_DEFAULT, H5P_DEFAULT);
H5Lcreate_external(FILE62, "type", source_fid, "ext_link3", H5P_DEFAULT, H5P_DEFAULT);
+ H5Lcreate_external(FILE62, "group/elink_t2", source_fid, "ext_link4", H5P_DEFAULT, H5P_DEFAULT);
+ H5Lcreate_external(FILE62, "empty_group", source_fid, "ext_link5", H5P_DEFAULT, H5P_DEFAULT);
/* close */
H5Fclose(source_fid);