summaryrefslogtreecommitdiffstats
path: root/tools/h5repack
diff options
context:
space:
mode:
authorPedro Vicente Nunes <pvn@hdfgroup.org>2003-12-17 14:07:41 (GMT)
committerPedro Vicente Nunes <pvn@hdfgroup.org>2003-12-17 14:07:41 (GMT)
commitcd7b4b8b90adc487f9cd4ee05f2425eeb5f7f84d (patch)
treed8f78540c20e8e338086b4bcb0d07374baf7d165 /tools/h5repack
parent52a46001cbeeb902d0fe7779ddcbbf0da0907c15 (diff)
downloadhdf5-cd7b4b8b90adc487f9cd4ee05f2425eeb5f7f84d.zip
hdf5-cd7b4b8b90adc487f9cd4ee05f2425eeb5f7f84d.tar.gz
hdf5-cd7b4b8b90adc487f9cd4ee05f2425eeb5f7f84d.tar.bz2
[svn-r7966] Purpose:
h5repack new features Description: added debugging functions and a hard link generated dataset for the test suite Solution: Platforms tested: linux solaris 2.7 IRIX Misc. update:
Diffstat (limited to 'tools/h5repack')
-rw-r--r--tools/h5repack/h5repack.c1
-rw-r--r--tools/h5repack/h5repack.h8
-rw-r--r--tools/h5repack/h5repack_copy.c5
-rw-r--r--tools/h5repack/testh5repack_dset.c4
4 files changed, 14 insertions, 4 deletions
diff --git a/tools/h5repack/h5repack.c b/tools/h5repack/h5repack.c
index b989ab3..24a90f7 100644
--- a/tools/h5repack/h5repack.c
+++ b/tools/h5repack/h5repack.c
@@ -57,6 +57,7 @@ int h5repack(const char* infile,
/* copy the file */
if (copy_file(infile,outfile,options)<0)
return -1;
+
return 0;
}
diff --git a/tools/h5repack/h5repack.h b/tools/h5repack/h5repack.h
index 9e857e7..546ae3a 100644
--- a/tools/h5repack/h5repack.h
+++ b/tools/h5repack/h5repack.h
@@ -19,6 +19,10 @@
#include "hdf5.h"
#include "h5trav.h"
+#if 0
+#define H5_REPACK_DEBUG
+#endif
+
#define PFORMAT "%-7s %-7s %-7s\n" /*chunk info, compression info, name*/
#define PFORMAT1 "%-7s %-7s %-7s" /*chunk info, compression info, name*/
@@ -26,10 +30,6 @@
#define MAX_NC_NAME 256 /* max length of a name */
#define MAX_VAR_DIMS 32 /* max per variable dimensions */
-#if 1
-#define H5_REPACK_DEBUG
-#endif
-
/*-------------------------------------------------------------------------
* data structures for command line options
diff --git a/tools/h5repack/h5repack_copy.c b/tools/h5repack/h5repack_copy.c
index f236889..f7d5016 100644
--- a/tools/h5repack/h5repack_copy.c
+++ b/tools/h5repack/h5repack_copy.c
@@ -109,6 +109,11 @@ int copy_file(const char* fnamein,
return -1;
}
+#if defined (H5_REPACK_DEBUG)
+ h5trav_printinfo(nobjects,travi);
+#endif
+
+
/*-------------------------------------------------------------------------
* free
*-------------------------------------------------------------------------
diff --git a/tools/h5repack/testh5repack_dset.c b/tools/h5repack/testh5repack_dset.c
index e5fe500..88363f7 100644
--- a/tools/h5repack/testh5repack_dset.c
+++ b/tools/h5repack/testh5repack_dset.c
@@ -168,6 +168,10 @@ void write_dset_in(hid_t loc_id,
write_dset(loc_id,1,dims,"string",type_id,buf1);
status = H5Tclose(type_id);
+
+ /* create hard link */
+ status = H5Glink(loc_id, H5G_LINK_HARD, "string", "string_link");
+
/*-------------------------------------------------------------------------
* H5T_BITFIELD
*-------------------------------------------------------------------------