summaryrefslogtreecommitdiffstats
path: root/tools/h5ls/h5ls.c
diff options
context:
space:
mode:
authorVailin Choi <vchoi@hdfgroup.org>2014-06-23 20:24:08 (GMT)
committerVailin Choi <vchoi@hdfgroup.org>2014-06-23 20:24:08 (GMT)
commit9158e8aa03227a294739aed5549ab14c1d04fb5c (patch)
treeb201f1d5616b04576de70d5043d196fbe199b06d /tools/h5ls/h5ls.c
parent67ba5eb6e8a71a110d47fd3079edcc1fe09fb95f (diff)
downloadhdf5-9158e8aa03227a294739aed5549ab14c1d04fb5c.zip
hdf5-9158e8aa03227a294739aed5549ab14c1d04fb5c.tar.gz
hdf5-9158e8aa03227a294739aed5549ab14c1d04fb5c.tar.bz2
[svn-r25342] Bring revisions #25120 - #25266 from trunk to revise_chunks.
Tested on jam, koala, ostrich, platypus.
Diffstat (limited to 'tools/h5ls/h5ls.c')
-rw-r--r--tools/h5ls/h5ls.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/tools/h5ls/h5ls.c b/tools/h5ls/h5ls.c
index 3c5ba06..42fb69f 100644
--- a/tools/h5ls/h5ls.c
+++ b/tools/h5ls/h5ls.c
@@ -817,8 +817,6 @@ print_float_type(h5tools_str_t *buffer, hid_t type, int ind)
* Programmer: Robb Matzke
* Thursday, November 5, 1998
*
- * Modifications:
- *
*-------------------------------------------------------------------------
*/
static hbool_t
@@ -833,8 +831,7 @@ print_cmpd_type(h5tools_str_t *buffer, hid_t type, int ind)
if(H5T_COMPOUND != H5Tget_class(type))
return FALSE;
- nmembs = H5Tget_nmembers(type);
- if(nmembs <= 0)
+ if((nmembs = H5Tget_nmembers(type)) < 0)
return FALSE;
h5tools_str_append(buffer, "struct {");
@@ -856,6 +853,7 @@ print_cmpd_type(h5tools_str_t *buffer, hid_t type, int ind)
size = H5Tget_size(type);
h5tools_str_append(buffer, "\n%*s} %lu byte%s",
ind, "", (unsigned long)size, 1==size?"":"s");
+
return TRUE;
}
@@ -884,8 +882,7 @@ print_enum_type(h5tools_str_t *buffer, hid_t type, int ind)
if(H5T_ENUM != H5Tget_class(type))
return FALSE;
- nmembs = H5Tget_nmembers(type);
- if(nmembs < 0)
+ if((nmembs = H5Tget_nmembers(type)) < 0)
return FALSE;
super = H5Tget_super(type);