diff options
Diffstat (limited to 'tools/h5dump')
-rw-r--r-- | tools/h5dump/h5dump_ddl.c | 54 | ||||
-rw-r--r-- | tools/h5dump/h5dump_xml.c | 64 | ||||
-rw-r--r-- | tools/h5dump/h5dumpgentest.c | 4 |
3 files changed, 61 insertions, 61 deletions
diff --git a/tools/h5dump/h5dump_ddl.c b/tools/h5dump/h5dump_ddl.c index c9e5571..f53a9d2 100644 --- a/tools/h5dump/h5dump_ddl.c +++ b/tools/h5dump/h5dump_ddl.c @@ -280,12 +280,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -323,12 +323,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -411,12 +411,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->softlinkblockend)) { + if(HDstrlen(h5tools_dump_header_format->softlinkblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->softlinkblockend); - if(strlen(h5tools_dump_header_format->softlinkend)) + if(HDstrlen(h5tools_dump_header_format->softlinkend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->softlinkend)) + if(HDstrlen(h5tools_dump_header_format->softlinkend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->softlinkend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -482,12 +482,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->extlinkblockend)) { + if(HDstrlen(h5tools_dump_header_format->extlinkblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->extlinkblockend); - if(strlen(h5tools_dump_header_format->extlinkend)) + if(HDstrlen(h5tools_dump_header_format->extlinkend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->extlinkend)) + if(HDstrlen(h5tools_dump_header_format->extlinkend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->extlinkend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -520,12 +520,12 @@ dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNUSED h5tools_simple_prefix(stdout, outputformat, &ctx, 0, 0); /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->udlinkblockend)) { + if(HDstrlen(h5tools_dump_header_format->udlinkblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->udlinkblockend); - if(strlen(h5tools_dump_header_format->udlinkend)) + if(HDstrlen(h5tools_dump_header_format->udlinkend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->udlinkend)) + if(HDstrlen(h5tools_dump_header_format->udlinkend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->udlinkend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -680,12 +680,12 @@ dump_named_datatype(hid_t tid, const char *name) done: /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datatypeblockend)) { + if(HDstrlen(h5tools_dump_header_format->datatypeblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datatypeblockend); - if(strlen(h5tools_dump_header_format->datatypeend)) + if(HDstrlen(h5tools_dump_header_format->datatypeend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datatypeend)) + if(HDstrlen(h5tools_dump_header_format->datatypeend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datatypeend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -886,12 +886,12 @@ dump_group(hid_t gid, const char *name) /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->groupblockend)) { + if(HDstrlen(h5tools_dump_header_format->groupblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->groupblockend); - if(strlen(h5tools_dump_header_format->groupend)) + if(HDstrlen(h5tools_dump_header_format->groupend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->groupend)) + if(HDstrlen(h5tools_dump_header_format->groupend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->groupend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -1073,12 +1073,12 @@ dump_dataset(hid_t did, const char *name, struct subset_t *sset) /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -1395,12 +1395,12 @@ handle_attributes(hid_t fid, const char *attr, void UNUSED * data, int UNUSED pe h5tools_simple_prefix(stdout, outputformat, &ctx, 0, 0); /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->attributeblockend)) { + if(HDstrlen(h5tools_dump_header_format->attributeblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->attributeblockend); - if(strlen(h5tools_dump_header_format->attributeend)) + if(HDstrlen(h5tools_dump_header_format->attributeend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->attributeend)) + if(HDstrlen(h5tools_dump_header_format->attributeend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->attributeend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); diff --git a/tools/h5dump/h5dump_xml.c b/tools/h5dump/h5dump_xml.c index 5b6cba1..934682c 100644 --- a/tools/h5dump/h5dump_xml.c +++ b/tools/h5dump/h5dump_xml.c @@ -172,12 +172,12 @@ xml_dump_all_cb(hid_t group, const char *name, const H5L_info_t *linfo, void UNU /* Render the element */ h5tools_str_reset(&buffer); - if(strlen(h5tools_dump_header_format->datasetblockend)) { + if(HDstrlen(h5tools_dump_header_format->datasetblockend)) { h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetblockend); - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, " "); } - if(strlen(h5tools_dump_header_format->datasetend)) + if(HDstrlen(h5tools_dump_header_format->datasetend)) h5tools_str_append(&buffer, "%s", h5tools_dump_header_format->datasetend); h5tools_render_element(stdout, outputformat, &ctx, &buffer, &curr_pos, outputformat->line_ncols, 0, 0); @@ -567,24 +567,24 @@ xml_escape_the_name(const char *str) return NULL; cp = str; - len = strlen(str); + len = HDstrlen(str); extra = 0; for (i = 0; i < len; i++) { if (*cp == '\"') { - extra += (strlen(quote) - 1); + extra += (HDstrlen(quote) - 1); } else if (*cp == '\'') { - extra += (strlen(apos) - 1); + extra += (HDstrlen(apos) - 1); } else if (*cp == '<') { - extra += (strlen(lt) - 1); + extra += (HDstrlen(lt) - 1); } else if (*cp == '>') { - extra += (strlen(gt) - 1); + extra += (HDstrlen(gt) - 1); } else if (*cp == '&') { - extra += (strlen(amp) - 1); + extra += (HDstrlen(amp) - 1); } cp++; @@ -601,28 +601,28 @@ xml_escape_the_name(const char *str) for (i = 0; i < len; i++) { if (*cp == '\'') { - strncpy(ncp, apos, strlen(apos)); - ncp += strlen(apos); + strncpy(ncp, apos, HDstrlen(apos)); + ncp += HDstrlen(apos); cp++; } else if (*cp == '<') { - strncpy(ncp, lt, strlen(lt)); - ncp += strlen(lt); + strncpy(ncp, lt, HDstrlen(lt)); + ncp += HDstrlen(lt); cp++; } else if (*cp == '>') { - strncpy(ncp, gt, strlen(gt)); - ncp += strlen(gt); + strncpy(ncp, gt, HDstrlen(gt)); + ncp += HDstrlen(gt); cp++; } else if (*cp == '\"') { - strncpy(ncp, quote, strlen(quote)); - ncp += strlen(quote); + strncpy(ncp, quote, HDstrlen(quote)); + ncp += HDstrlen(quote); cp++; } else if (*cp == '&') { - strncpy(ncp, amp, strlen(amp)); - ncp += strlen(amp); + strncpy(ncp, amp, HDstrlen(amp)); + ncp += HDstrlen(amp); cp++; } else { @@ -664,7 +664,7 @@ xml_escape_the_string(const char *str, int slen) cp = str; if (slen < 0) - len = strlen(str); + len = HDstrlen(str); else len = slen; @@ -678,16 +678,16 @@ xml_escape_the_string(const char *str, int slen) extra++; } else if (*cp == '\'') { - extra += (strlen(apos) - 1); + extra += (HDstrlen(apos) - 1); } else if (*cp == '<') { - extra += (strlen(lt) - 1); + extra += (HDstrlen(lt) - 1); } else if (*cp == '>') { - extra += (strlen(gt) - 1); + extra += (HDstrlen(gt) - 1); } else if (*cp == '&') { - extra += (strlen(amp) - 1); + extra += (HDstrlen(amp) - 1); } cp++; } @@ -708,23 +708,23 @@ xml_escape_the_string(const char *str, int slen) *ncp++ = *cp++; } else if (*cp == '\'') { - strncpy(ncp, apos, strlen(apos)); - ncp += strlen(apos); + strncpy(ncp, apos, HDstrlen(apos)); + ncp += HDstrlen(apos); cp++; } else if (*cp == '<') { - strncpy(ncp, lt, strlen(lt)); - ncp += strlen(lt); + strncpy(ncp, lt, HDstrlen(lt)); + ncp += HDstrlen(lt); cp++; } else if (*cp == '>') { - strncpy(ncp, gt, strlen(gt)); - ncp += strlen(gt); + strncpy(ncp, gt, HDstrlen(gt)); + ncp += HDstrlen(gt); cp++; } else if (*cp == '&') { - strncpy(ncp, amp, strlen(amp)); - ncp += strlen(amp); + strncpy(ncp, amp, HDstrlen(amp)); + ncp += HDstrlen(amp); cp++; } else { diff --git a/tools/h5dump/h5dumpgentest.c b/tools/h5dump/h5dumpgentest.c index f87f93a..5b97434 100644 --- a/tools/h5dump/h5dumpgentest.c +++ b/tools/h5dump/h5dumpgentest.c @@ -3528,7 +3528,7 @@ void gent_split_file(void) root = H5Gopen2(fid, "/", H5P_DEFAULT); atype = H5Tcopy(H5T_C_S1); - H5Tset_size(atype, strlen(meta) + 1); + H5Tset_size(atype, HDstrlen(meta) + 1); H5Tset_strpad(atype, H5T_STR_NULLTERM); dims[0] = 1; @@ -3729,7 +3729,7 @@ static void gent_char(void) hid_t sid1; /* Dataspace ID */ hsize_t dims1[1]; - dims1[0] = strlen(wdata); + dims1[0] = HDstrlen(wdata); /* Create file */ fid1 = H5Fcreate(FILE39, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); |