diff options
author | Dana Robinson <43805+derobins@users.noreply.github.com> | 2023-09-05 18:50:06 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-05 18:50:06 (GMT) |
commit | ae1379094b71c51342772397af5caca088862a61 (patch) | |
tree | e79cb67a1227bfdec099f62e9df22917213b8a7d /tools/src/h5stat | |
parent | d24f5d5223731d507b51d112ba564d764d6d6c18 (diff) | |
download | hdf5-ae1379094b71c51342772397af5caca088862a61.zip hdf5-ae1379094b71c51342772397af5caca088862a61.tar.gz hdf5-ae1379094b71c51342772397af5caca088862a61.tar.bz2 |
hbool_t/TRUE/FALSE --> bool/true/false in tools (#3491)
Diffstat (limited to 'tools/src/h5stat')
-rw-r--r-- | tools/src/h5stat/h5stat.c | 102 |
1 files changed, 51 insertions, 51 deletions
diff --git a/tools/src/h5stat/h5stat.c b/tools/src/h5stat/h5stat.c index 5cfa61d..bb4e58a 100644 --- a/tools/src/h5stat/h5stat.c +++ b/tools/src/h5stat/h5stat.c @@ -101,7 +101,7 @@ typedef struct iter_t { hsize_t super_ext_size; /* superblock extension size */ hsize_t ublk_size; /* user block size (if exists) */ H5F_fspace_strategy_t fs_strategy; /* File space management strategy */ - hbool_t fs_persist; /* Free-space persist or not */ + bool fs_persist; /* Free-space persist or not */ hsize_t fs_threshold; /* Free-space section threshold */ hsize_t fsp_size; /* File space page size */ hsize_t free_space; /* Amount of freespace in the file */ @@ -122,7 +122,7 @@ static const char *drivername = NULL; static H5FD_ros3_fapl_ext_t ros3_fa = { { 1, /* Structure Version */ - FALSE, /* Authenticate? */ + false, /* Authenticate? */ "", /* AWS Region */ "", /* Access Key ID */ "", /* Secret Access Key */ @@ -143,22 +143,22 @@ static H5FD_hdfs_fapl_t hdfs_fa = { }; #endif /* H5_HAVE_LIBHDFS */ -static int display_all = TRUE; +static int display_all = true; /* Enable the printing of selected statistics */ -static int display_file = FALSE; /* display file information */ -static int display_group = FALSE; /* display groups information */ -static int display_dset = FALSE; /* display datasets information */ -static int display_dset_dtype_meta = FALSE; /* display datasets' datatype information */ -static int display_attr = FALSE; /* display attributes information */ -static int display_free_sections = FALSE; /* display free space information */ -static int display_summary = FALSE; /* display summary of file space information */ +static int display_file = false; /* display file information */ +static int display_group = false; /* display groups information */ +static int display_dset = false; /* display datasets information */ +static int display_dset_dtype_meta = false; /* display datasets' datatype information */ +static int display_attr = false; /* display attributes information */ +static int display_free_sections = false; /* display free space information */ +static int display_summary = false; /* display summary of file space information */ -static int display_file_metadata = FALSE; /* display file space info for file's metadata */ -static int display_group_metadata = FALSE; /* display file space info for groups' metadata */ -static int display_dset_metadata = FALSE; /* display file space info for datasets' metadata */ +static int display_file_metadata = false; /* display file space info for file's metadata */ +static int display_group_metadata = false; /* display file space info for groups' metadata */ +static int display_dset_metadata = false; /* display file space info for datasets' metadata */ -static int display_object = FALSE; /* not implemented yet */ +static int display_object = false; /* not implemented yet */ /* Initialize threshold for small groups/datasets/attributes */ static int sgroups_threshold = DEF_SIZE_SMALL_GROUPS; @@ -516,10 +516,10 @@ dataset_stats(iter_t *iter, const char *name, const H5O_info2_t *oi, const H5O_n if ((tid = H5Dget_type(did)) < 0) H5TOOLS_GOTO_ERROR(FAIL, "H5Dget_type() failed"); - type_found = FALSE; + type_found = false; for (u = 0; u < iter->dset_ntypes; u++) if (H5Tequal(iter->dset_type_info[u].tid, tid) > 0) { - type_found = TRUE; + type_found = true; break; } /* end for */ @@ -825,23 +825,23 @@ parse_command_line(int argc, const char *const *argv, struct handler_t **hand_re break; case 'F': - display_all = FALSE; - display_file_metadata = TRUE; + display_all = false; + display_file_metadata = true; break; case 'f': - display_all = FALSE; - display_file = TRUE; + display_all = false; + display_file = true; break; case 'G': - display_all = FALSE; - display_group_metadata = TRUE; + display_all = false; + display_group_metadata = true; break; case 'g': - display_all = FALSE; - display_group = TRUE; + display_all = false; + display_group = true; break; case 'l': @@ -858,13 +858,13 @@ parse_command_line(int argc, const char *const *argv, struct handler_t **hand_re break; case 'D': - display_all = FALSE; - display_dset_metadata = TRUE; + display_all = false; + display_dset_metadata = true; break; case 'd': - display_all = FALSE; - display_dset = TRUE; + display_all = false; + display_dset = true; break; case 'm': @@ -881,13 +881,13 @@ parse_command_line(int argc, const char *const *argv, struct handler_t **hand_re break; case 'T': - display_all = FALSE; - display_dset_dtype_meta = TRUE; + display_all = false; + display_dset_dtype_meta = true; break; case 'A': - display_all = FALSE; - display_attr = TRUE; + display_all = false; + display_attr = true; break; case 'a': @@ -904,18 +904,18 @@ parse_command_line(int argc, const char *const *argv, struct handler_t **hand_re break; case 's': - display_all = FALSE; - display_free_sections = TRUE; + display_all = false; + display_free_sections = true; break; case 'S': - display_all = FALSE; - display_summary = TRUE; + display_all = false; + display_summary = true; break; case 'O': - display_all = FALSE; - display_object = TRUE; + display_all = false; + display_object = true; /* Allocate space to hold the command line info */ if (NULL == (hand = (struct handler_t *)calloc((size_t)1, sizeof(struct handler_t)))) { @@ -1514,17 +1514,17 @@ static void print_file_statistics(const iter_t *iter) { if (display_all) { - display_file = TRUE; - display_group = TRUE; - display_dset = TRUE; - display_dset_dtype_meta = TRUE; - display_attr = TRUE; - display_free_sections = TRUE; - display_summary = TRUE; - - display_file_metadata = TRUE; - display_group_metadata = TRUE; - display_dset_metadata = TRUE; + display_file = true; + display_group = true; + display_dset = true; + display_dset_dtype_meta = true; + display_attr = true; + display_free_sections = true; + display_summary = true; + + display_file_metadata = true; + display_group_metadata = true; + display_dset_metadata = true; } if (display_file) @@ -1708,7 +1708,7 @@ main(int argc, char *argv[]) unsigned u; for (u = 0; u < hand->obj_count; u++) { - if (h5trav_visit(fid, hand->obj[u], TRUE, TRUE, obj_stats, lnk_stats, &iter, H5O_INFO_ALL) < + if (h5trav_visit(fid, hand->obj[u], true, true, obj_stats, lnk_stats, &iter, H5O_INFO_ALL) < 0) { error_msg("unable to traverse object \"%s\"\n", hand->obj[u]); h5tools_setstatus(EXIT_FAILURE); @@ -1718,7 +1718,7 @@ main(int argc, char *argv[]) } /* end for */ } /* end if */ else { - if (h5trav_visit(fid, "/", TRUE, TRUE, obj_stats, lnk_stats, &iter, H5O_INFO_ALL) < 0) { + if (h5trav_visit(fid, "/", true, true, obj_stats, lnk_stats, &iter, H5O_INFO_ALL) < 0) { error_msg("unable to traverse objects/links in file \"%s\"\n", fname); h5tools_setstatus(EXIT_FAILURE); } |