summaryrefslogtreecommitdiffstats
path: root/tools/lib
diff options
context:
space:
mode:
authorVailin Choi <vchoi@hdfgroup.org>2015-04-21 02:52:07 (GMT)
committerVailin Choi <vchoi@hdfgroup.org>2015-04-21 02:52:07 (GMT)
commit3f36df51d845a93e94fff264fa22ad60a71db754 (patch)
tree0183dbf4cf0e6fa3020c51c019c09023a5e48a99 /tools/lib
parent76d509dd6f454de8b01d0116dc73e56ea5949aa8 (diff)
downloadhdf5-3f36df51d845a93e94fff264fa22ad60a71db754.zip
hdf5-3f36df51d845a93e94fff264fa22ad60a71db754.tar.gz
hdf5-3f36df51d845a93e94fff264fa22ad60a71db754.tar.bz2
[svn-r26859] Bring revisions #26324 - #26843 from trunk to revise_chunks.
h5committested.
Diffstat (limited to 'tools/lib')
-rw-r--r--tools/lib/Makefile.in5
-rw-r--r--tools/lib/h5tools_filters.c32
-rw-r--r--tools/lib/h5trav.c16
-rw-r--r--tools/lib/io_timer.c2
4 files changed, 13 insertions, 42 deletions
diff --git a/tools/lib/Makefile.in b/tools/lib/Makefile.in
index 607f1ed..c972bab 100644
--- a/tools/lib/Makefile.in
+++ b/tools/lib/Makefile.in
@@ -454,7 +454,6 @@ FCFLAGS_f90 = @FCFLAGS_f90@
FCLIBS = @FCLIBS@
FC_VERSION = @FC_VERSION@
FGREP = @FGREP@
-FILTERS = @FILTERS@
FSEARCH_DIRS = @FSEARCH_DIRS@
GREP = @GREP@
H5_CFLAGS = @H5_CFLAGS@
@@ -542,10 +541,6 @@ TR = @TR@
TRACE_API = @TRACE_API@
UNAME_INFO = @UNAME_INFO@
USE_FILTER_DEFLATE = @USE_FILTER_DEFLATE@
-USE_FILTER_FLETCHER32 = @USE_FILTER_FLETCHER32@
-USE_FILTER_NBIT = @USE_FILTER_NBIT@
-USE_FILTER_SCALEOFFSET = @USE_FILTER_SCALEOFFSET@
-USE_FILTER_SHUFFLE = @USE_FILTER_SHUFFLE@
USE_FILTER_SZIP = @USE_FILTER_SZIP@
USINGMEMCHECKER = @USINGMEMCHECKER@
VERSION = @VERSION@
diff --git a/tools/lib/h5tools_filters.c b/tools/lib/h5tools_filters.c
index 79cf253..ccdba26 100644
--- a/tools/lib/h5tools_filters.c
+++ b/tools/lib/h5tools_filters.c
@@ -107,44 +107,24 @@ int h5tools_canreadf(const char* name, /* object name, serves also as boolean pr
*-------------------------------------------------------------------------
*/
case H5Z_FILTER_SHUFFLE:
-#ifndef H5_HAVE_FILTER_SHUFFLE
- if (name)
- print_warning(name,"shuffle");
- return 0;
-#endif
break;
/*-------------------------------------------------------------------------
* H5Z_FILTER_FLETCHER32 3 , fletcher32 checksum of EDC
*-------------------------------------------------------------------------
*/
case H5Z_FILTER_FLETCHER32:
-#ifndef H5_HAVE_FILTER_FLETCHER32
- if (name)
- print_warning(name,"fletcher32");
- return 0;
-#endif
break;
/*-------------------------------------------------------------------------
* H5Z_FILTER_NBIT
*-------------------------------------------------------------------------
*/
case H5Z_FILTER_NBIT:
-#ifndef H5_HAVE_FILTER_NBIT
- if (name)
- print_warning(name,"nbit");
- return 0;
-#endif
break;
/*-------------------------------------------------------------------------
* H5Z_FILTER_SCALEOFFSET
*-------------------------------------------------------------------------
*/
case H5Z_FILTER_SCALEOFFSET:
-#ifndef H5_HAVE_FILTER_SCALEOFFSET
- if (name)
- print_warning(name,"scaleoffset");
- return 0;
-#endif
break;
}/*switch*/
}/*for*/
@@ -211,24 +191,12 @@ int h5tools_can_encode(H5Z_filter_t filtn) {
#endif
break;
case H5Z_FILTER_SHUFFLE:
-#ifndef H5_HAVE_FILTER_SHUFFLE
- return 0;
-#endif
break;
case H5Z_FILTER_FLETCHER32:
-#ifndef H5_HAVE_FILTER_FLETCHER32
- return 0;
-#endif
break;
case H5Z_FILTER_NBIT:
-#ifndef H5_HAVE_FILTER_NBIT
- return 0;
-#endif
break;
case H5Z_FILTER_SCALEOFFSET:
-#ifndef H5_HAVE_FILTER_SCALEOFFSET
- return 0;
-#endif
break;
}/*switch*/
diff --git a/tools/lib/h5trav.c b/tools/lib/h5trav.c
index d0a4a76..90e6d3d 100644
--- a/tools/lib/h5trav.c
+++ b/tools/lib/h5trav.c
@@ -50,6 +50,10 @@ typedef struct {
hid_t fid; /* File ID being traversed */
} trav_print_udata_t;
+typedef struct trav_path_op_data_t {
+ const char *path;
+} trav_path_op_data_t;
+
/* format for hsize_t */
#ifdef H5TRAV_PRINT_SPACE
#define HSIZE_T_FORMAT "%" H5_PRINTF_LL_WIDTH "u"
@@ -899,11 +903,11 @@ trav_attr(hid_t
#ifndef H5TRAV_PRINT_SPACE
UNUSED
#endif /* H5TRAV_PRINT_SPACE */
-obj, const char *attr_name, const H5A_info_t UNUSED *ainfo, void *op_data)
+obj, const char *attr_name, const H5A_info_t UNUSED *ainfo, void *_op_data)
{
- char *buf;
+ trav_path_op_data_t *op_data = (trav_path_op_data_t *)_op_data;
+ const char *buf = op_data->path;
- buf = (char*)op_data;
if((strlen(buf)==1) && (*buf=='/'))
printf(" %-10s %s%s", "attribute", buf, attr_name);
else
@@ -1009,10 +1013,14 @@ trav_print_visit_obj(const char *path, const H5O_info_t *oinfo,
/* Check if we've already seen this object */
if(NULL == already_visited) {
+ trav_path_op_data_t op_data;
+
+ op_data.path = path;
/* Finish printing line about object */
printf("\n");
if(trav_verbosity > 0)
- H5Aiterate_by_name(print_udata->fid, path, trav_index_by, trav_index_order, NULL, trav_attr, (void *)path, H5P_DEFAULT);
+ H5Aiterate_by_name(print_udata->fid, path, trav_index_by, trav_index_order,
+ NULL, trav_attr, &op_data, H5P_DEFAULT);
}
else
/* Print the link's original name */
diff --git a/tools/lib/io_timer.c b/tools/lib/io_timer.c
index 78e7fe9..b8d44de 100644
--- a/tools/lib/io_timer.c
+++ b/tools/lib/io_timer.c
@@ -40,7 +40,7 @@
* The number to divide the tv_usec field with to get a nice decimal to add to
* the number of seconds.
*/
-#define MICROSECOND 1000000.0
+#define MICROSECOND 1000000.0F
/* global variables */
io_time_t *timer_g; /* timer: global for stub functions */