diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/H5.c | 4 | ||||
-rw-r--r-- | src/H5AC.c | 2 | ||||
-rw-r--r-- | src/H5FDmpio.c | 2 | ||||
-rw-r--r-- | src/H5FDonion.c | 12 | ||||
-rw-r--r-- | src/H5FDs3comms.c | 4 | ||||
-rw-r--r-- | src/H5FDsubfiling/H5subfiling_common.c | 10 | ||||
-rw-r--r-- | src/H5private.h | 18 | ||||
-rw-r--r-- | src/H5trace.c | 2 |
8 files changed, 18 insertions, 36 deletions
@@ -745,7 +745,7 @@ H5__debug_mask(const char *s) } /* end if-else */ } else if (HDisdigit(*s)) { - int fd = (int)HDstrtol(s, &rest, 0); + int fd = (int)strtol(s, &rest, 0); H5_debug_open_stream_t *open_stream; if ((stream = HDfdopen(fd, "w")) != NULL) { @@ -889,7 +889,7 @@ H5check_version(unsigned majnum, unsigned minnum, unsigned relnum) s = HDgetenv("HDF5_DISABLE_VERSION_CHECK"); if (s && HDisdigit(*s)) - disable_version_check = (unsigned int)HDstrtol(s, NULL, 0); + disable_version_check = (unsigned int)strtol(s, NULL, 0); } /* H5_VERS_MAJOR and H5_VERS_MINOR must match */ @@ -150,7 +150,7 @@ H5AC_init(void) s = HDgetenv("H5_COLL_API_SANITY_CHECK"); if (s && HDisdigit(*s)) { - long env_val = HDstrtol(s, NULL, 0); + long env_val = strtol(s, NULL, 0); H5_coll_api_sanity_check_g = (0 == env_val) ? FALSE : TRUE; } } diff --git a/src/H5FDmpio.c b/src/H5FDmpio.c index 52370f1..fbe1d86 100644 --- a/src/H5FDmpio.c +++ b/src/H5FDmpio.c @@ -291,7 +291,7 @@ H5FD_mpio_init(void) /* Allow MPI buf-and-file-type optimizations? */ s = HDgetenv("HDF5_MPI_OPT_TYPES"); if (s && HDisdigit(*s)) - H5FD_mpi_opt_types_g = (0 == HDstrtol(s, NULL, 0)) ? FALSE : TRUE; + H5FD_mpi_opt_types_g = (0 == strtol(s, NULL, 0)) ? FALSE : TRUE; #ifdef H5FDmpio_DEBUG /* Clear the flag buffer */ diff --git a/src/H5FDonion.c b/src/H5FDonion.c index af96f81..ac46707 100644 --- a/src/H5FDonion.c +++ b/src/H5FDonion.c @@ -817,7 +817,7 @@ H5FD__onion_parse_config_str(const char *config_str, H5FD_onion_fapl_info_t *fa) * e.g. {revision_num: 2; page_size: 4;} */ if (config_str[0] != '{') - fa->revision_num = (uint64_t)HDstrtoull(config_str, NULL, 10); + fa->revision_num = (uint64_t)strtoull(config_str, NULL, 10); else { char *token1 = NULL, *token2 = NULL; @@ -847,22 +847,22 @@ H5FD__onion_parse_config_str(const char *config_str, H5FD_onion_fapl_info_t *fa) else if (!strcmp(token2, "H5I_INVALID_HID")) fa->backing_fapl_id = H5I_INVALID_HID; else - fa->backing_fapl_id = HDstrtoll(token2, NULL, 10); + fa->backing_fapl_id = strtoll(token2, NULL, 10); } else if (!HDstrcmp(token1, "page_size")) { - fa->page_size = (uint32_t)HDstrtoul(token2, NULL, 10); + fa->page_size = (uint32_t)strtoul(token2, NULL, 10); } else if (!HDstrcmp(token1, "revision_num")) { if (!HDstrcmp(token2, "H5FD_ONION_FAPL_INFO_REVISION_ID_LATEST")) fa->revision_num = H5FD_ONION_FAPL_INFO_REVISION_ID_LATEST; else - fa->revision_num = (uint64_t)HDstrtoull(token2, NULL, 10); + fa->revision_num = (uint64_t)strtoull(token2, NULL, 10); } else if (!HDstrcmp(token1, "force_write_open")) { - fa->force_write_open = (uint8_t)HDstrtoul(token2, NULL, 10); + fa->force_write_open = (uint8_t)strtoul(token2, NULL, 10); } else if (!HDstrcmp(token1, "creation_flags")) { - fa->creation_flags = (uint8_t)HDstrtoul(token2, NULL, 10); + fa->creation_flags = (uint8_t)strtoul(token2, NULL, 10); } else if (!HDstrcmp(token1, "comment")) { HDstrcpy(fa->comment, token2); diff --git a/src/H5FDs3comms.c b/src/H5FDs3comms.c index c088fca..5d958b5 100644 --- a/src/H5FDs3comms.c +++ b/src/H5FDs3comms.c @@ -955,11 +955,11 @@ H5FD_s3comms_s3r_getsize(s3r_t *handle) */ *end = '\0'; - content_length = HDstrtoumax((const char *)start, NULL, 0); + content_length = strtoumax((const char *)start, NULL, 0); if (UINTMAX_MAX > SIZE_MAX && content_length > SIZE_MAX) HGOTO_ERROR(H5E_ARGS, H5E_OVERFLOW, FAIL, "content_length overflows size_t"); - if (content_length == 0 || errno == ERANGE) /* errno set by HDstrtoumax*/ + if (content_length == 0 || errno == ERANGE) /* errno set by strtoumax*/ HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "could not convert found \"Content-Length\" response (\"%s\")", start); /* range is null-terminated, remember */ diff --git a/src/H5FDsubfiling/H5subfiling_common.c b/src/H5FDsubfiling/H5subfiling_common.c index 3ef9344..5c8d366 100644 --- a/src/H5FDsubfiling/H5subfiling_common.c +++ b/src/H5FDsubfiling/H5subfiling_common.c @@ -860,7 +860,7 @@ init_subfiling(const char *base_filename, uint64_t file_id, H5FD_subfiling_param errno = 0; - stripe_size = HDstrtoll(env_value, NULL, 0); + stripe_size = strtoll(env_value, NULL, 0); if (ERANGE == errno) H5_SUBFILING_SYS_GOTO_ERROR(H5E_VFL, H5E_BADVALUE, FAIL, "invalid stripe size setting for " H5FD_SUBFILING_STRIPE_SIZE); @@ -987,7 +987,7 @@ init_app_topology(H5FD_subfiling_params_t *subfiling_config, MPI_Comm comm, MPI_ /* Check for an IOC-per-node value set in the environment */ if ((env_value = HDgetenv(H5FD_SUBFILING_IOC_PER_NODE))) { errno = 0; - ioc_select_val = HDstrtol(env_value, NULL, 0); + ioc_select_val = strtol(env_value, NULL, 0); if ((ERANGE == errno)) { printf("invalid value '%s' for " H5FD_SUBFILING_IOC_PER_NODE "\n", env_value); ioc_select_val = 1; @@ -1014,7 +1014,7 @@ init_app_topology(H5FD_subfiling_params_t *subfiling_config, MPI_Comm comm, MPI_ ioc_select_val = 1; if (ioc_sel_str) { errno = 0; - ioc_select_val = HDstrtol(ioc_sel_str, NULL, 0); + ioc_select_val = strtol(ioc_sel_str, NULL, 0); if ((ERANGE == errno) || (ioc_select_val <= 0)) { printf("invalid IOC selection strategy string '%s' for strategy " "SELECT_IOC_EVERY_NTH_RANK; defaulting to SELECT_IOC_ONE_PER_NODE\n", @@ -1050,7 +1050,7 @@ init_app_topology(H5FD_subfiling_params_t *subfiling_config, MPI_Comm comm, MPI_ ioc_select_val = 1; if (ioc_sel_str) { errno = 0; - ioc_select_val = HDstrtol(ioc_sel_str, NULL, 0); + ioc_select_val = strtol(ioc_sel_str, NULL, 0); if ((ERANGE == errno) || (ioc_select_val <= 0)) { printf("invalid IOC selection strategy string '%s' for strategy SELECT_IOC_TOTAL; " "defaulting to SELECT_IOC_ONE_PER_NODE\n", @@ -1213,7 +1213,7 @@ get_ioc_selection_criteria_from_env(H5FD_subfiling_ioc_select_t *ioc_selection_t *opt_value++ = '\0'; errno = 0; - check_value = HDstrtol(env_value, NULL, 0); + check_value = strtol(env_value, NULL, 0); if (errno == ERANGE) H5_SUBFILING_SYS_GOTO_ERROR(H5E_VFL, H5E_CANTGET, FAIL, diff --git a/src/H5private.h b/src/H5private.h index 25c02bf..0d1671c 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1077,30 +1077,12 @@ H5_DLL H5_ATTR_CONST int Nflock(int fd, int operation); #ifndef HDstrstr #define HDstrstr(X, Y) strstr(X, Y) #endif -#ifndef HDstrtod -#define HDstrtod(S, R) strtod(S, R) -#endif #ifndef HDstrtok #define HDstrtok(X, Y) strtok(X, Y) #endif #ifndef HDstrtok_r #define HDstrtok_r(X, Y, Z) strtok_r(X, Y, Z) #endif -#ifndef HDstrtol -#define HDstrtol(S, R, N) strtol(S, R, N) -#endif -#ifndef HDstrtoll -#define HDstrtoll(S, R, N) strtoll(S, R, N) -#endif -#ifndef HDstrtoul -#define HDstrtoul(S, R, N) strtoul(S, R, N) -#endif -#ifndef HDstrtoull -#define HDstrtoull(S, R, N) strtoull(S, R, N) -#endif -#ifndef HDstrtoumax -#define HDstrtoumax(S, R, N) strtoumax(S, R, N) -#endif #ifndef HDtime #define HDtime(T) time(T) #endif diff --git a/src/H5trace.c b/src/H5trace.c index 6608a52..4f81736 100644 --- a/src/H5trace.c +++ b/src/H5trace.c @@ -258,7 +258,7 @@ H5_trace_args(H5RS_str_t *rs, const char *type, va_list ap) char *rest; if ('a' == type[1]) { - asize_idx = (int)HDstrtol(type + 2, &rest, 10); + asize_idx = (int)strtol(type + 2, &rest, 10); assert(0 <= asize_idx && asize_idx < (int)NELMTS(asize)); assert(']' == *rest); type = rest + 1; |