summaryrefslogtreecommitdiffstats
path: root/tools/h5dump/h5dumpgentest.c
diff options
context:
space:
mode:
authorNeil Fortner <nfortne2@hdfgroup.org>2008-09-21 18:36:09 (GMT)
committerNeil Fortner <nfortne2@hdfgroup.org>2008-09-21 18:36:09 (GMT)
commit13f5dbc05db6d5a4c3bc6057ebb0a1c44a1a2410 (patch)
treef1dfd9dd5b850d15184728b9437bcec608d4f9b8 /tools/h5dump/h5dumpgentest.c
parent50f38c5e597a6234f95e757a7d61d227bcf0fe0d (diff)
downloadhdf5-13f5dbc05db6d5a4c3bc6057ebb0a1c44a1a2410.zip
hdf5-13f5dbc05db6d5a4c3bc6057ebb0a1c44a1a2410.tar.gz
hdf5-13f5dbc05db6d5a4c3bc6057ebb0a1c44a1a2410.tar.bz2
[svn-r15669] 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/h5dumpgentest.c')
-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);