summaryrefslogtreecommitdiffstats
path: root/tools/h5ls.c
diff options
context:
space:
mode:
authorRobb Matzke <matzke@llnl.gov>1999-05-04 13:12:42 (GMT)
committerRobb Matzke <matzke@llnl.gov>1999-05-04 13:12:42 (GMT)
commitc529ab9cc4bb04d5d22a193ce81ed3edbf456a65 (patch)
treee2788eb35f8bbff2f70b609d54f3d491bca8ef84 /tools/h5ls.c
parentca309999ba29d6c99237f004b26289f0791df45f (diff)
downloadhdf5-c529ab9cc4bb04d5d22a193ce81ed3edbf456a65.zip
hdf5-c529ab9cc4bb04d5d22a193ce81ed3edbf456a65.tar.gz
hdf5-c529ab9cc4bb04d5d22a193ce81ed3edbf456a65.tar.bz2
[svn-r1247] Checked in again
Diffstat (limited to 'tools/h5ls.c')
-rw-r--r--tools/h5ls.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/h5ls.c b/tools/h5ls.c
index 6dc1ed5..b686f7d 100644
--- a/tools/h5ls.c
+++ b/tools/h5ls.c
@@ -1237,7 +1237,7 @@ dataset_list2(hid_t dset, const char UNUSED *name)
(unsigned long)total, 1==total?"":"s");
if (total>0) {
#ifdef WIN32
- hsize_t mask = (hsize_1)1 << (8*sizeof(hsize_t)-1);
+ hsize_t mask = (hsize_t)1 << (8*sizeof(hsize_t)-1);
if ((used & mask) || (total & mask)) {
total = 0; /*prevent utilization printing*/
} else {
@@ -1246,7 +1246,7 @@ dataset_list2(hid_t dset, const char UNUSED *name)
#else
utilization = (used*100.0)/total;
#endif
- printf(", %1.2f%% utilization", (used*100.0)/total);
+ if (total) printf(", %1.2f%% utilization", utilization);
}
putchar('\n');