summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2023-06-29 15:18:49 (GMT)
committerGitHub <noreply@github.com>2023-06-29 15:18:49 (GMT)
commit8aef67f0ae3e037df22c5319eb2eac8b95521b19 (patch)
tree1286f3e2109b73a7040119779331814436110fae
parent9f430d15b004495d17826840ef1a4f281215c7f9 (diff)
downloadhdf5-8aef67f0ae3e037df22c5319eb2eac8b95521b19.zip
hdf5-8aef67f0ae3e037df22c5319eb2eac8b95521b19.tar.gz
hdf5-8aef67f0ae3e037df22c5319eb2eac8b95521b19.tar.bz2
Remove HD from strto* calls (#3204)
* HDstrtod * HDstrtol * HDstrtoll * HDstrtoul * HDstrtoull * HDstrtoumax
-rw-r--r--hl/tools/h5watch/h5watch.c6
-rw-r--r--src/H5.c4
-rw-r--r--src/H5AC.c2
-rw-r--r--src/H5FDmpio.c2
-rw-r--r--src/H5FDonion.c12
-rw-r--r--src/H5FDs3comms.c4
-rw-r--r--src/H5FDsubfiling/H5subfiling_common.c10
-rw-r--r--src/H5private.h18
-rw-r--r--src/H5trace.c2
-rw-r--r--test/big.c6
-rw-r--r--test/testframe.c2
-rw-r--r--test/use_common.c6
-rw-r--r--testpar/t_subfiling_vfd.c4
-rw-r--r--tools/lib/h5tools_utils.c6
-rw-r--r--tools/src/h5diff/h5diff_common.c6
-rw-r--r--tools/src/h5dump/h5dump.c2
-rw-r--r--tools/src/h5import/h5import.c22
-rw-r--r--tools/src/h5ls/h5ls.c8
-rw-r--r--tools/src/h5perf/pio_perf.c2
-rw-r--r--tools/src/h5perf/sio_engine.c2
-rw-r--r--tools/src/h5perf/sio_perf.c2
-rw-r--r--tools/src/h5repack/h5repack_main.c8
-rw-r--r--tools/src/h5repack/h5repack_parse.c12
-rw-r--r--tools/src/misc/h5debug.c4
-rw-r--r--tools/src/misc/h5repart.c4
-rw-r--r--tools/test/perform/zip_perf.c4
26 files changed, 71 insertions, 89 deletions
diff --git a/hl/tools/h5watch/h5watch.c b/hl/tools/h5watch/h5watch.c
index d2c0d90..b408741 100644
--- a/hl/tools/h5watch/h5watch.c
+++ b/hl/tools/h5watch/h5watch.c
@@ -689,7 +689,7 @@ parse_command_line(int argc, const char *const *argv)
break;
case 'w': /* --width=N */
- g_display_width = (int)HDstrtol(H5_optarg, NULL, 0);
+ g_display_width = (int)strtol(H5_optarg, NULL, 0);
if (g_display_width < 0) {
usage(h5tools_getprogname());
leave(EXIT_FAILURE);
@@ -709,8 +709,8 @@ parse_command_line(int argc, const char *const *argv)
break;
case 'p': /* --polling=N */
- /* g_polling_interval = HDstrtod(H5_optarg, NULL); */
- if ((tmp = (int)HDstrtol(H5_optarg, NULL, 10)) <= 0) {
+ /* g_polling_interval = strtod(H5_optarg, NULL); */
+ if ((tmp = (int)strtol(H5_optarg, NULL, 10)) <= 0) {
usage(h5tools_getprogname());
leave(EXIT_FAILURE);
}
diff --git a/src/H5.c b/src/H5.c
index 87a87ea..caa5636 100644
--- a/src/H5.c
+++ b/src/H5.c
@@ -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 */
diff --git a/src/H5AC.c b/src/H5AC.c
index 2cae74f..3a44147 100644
--- a/src/H5AC.c
+++ b/src/H5AC.c
@@ -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;
diff --git a/test/big.c b/test/big.c
index c582094..ef6bd5f 100644
--- a/test/big.c
+++ b/test/big.c
@@ -495,8 +495,8 @@ reader(char *filename, hid_t fapl)
while (HDfgets(ln, (int)sizeof(ln), script)) {
if ('#' != ln[0])
break;
- i = (int)HDstrtol(ln + 1, &s, 10);
- hs_offset[0] = HDstrtoull(s, NULL, 0);
+ i = (int)strtol(ln + 1, &s, 10);
+ hs_offset[0] = strtoull(s, NULL, 0);
fprintf(stdout, "#%03d 0x%016" PRIxHSIZE "%47s", i, hs_offset[0], "");
HDfflush(stdout);
@@ -741,7 +741,7 @@ main(int ac, char **av)
ac--;
av++;
if (ac > 0) {
- family_size_def = (hsize_t)HDstrtoull(*av, NULL, 0);
+ family_size_def = (hsize_t)strtoull(*av, NULL, 0);
}
else {
printf("***Missing fsize value***\n");
diff --git a/test/testframe.c b/test/testframe.c
index f472b2e..bb760f8 100644
--- a/test/testframe.c
+++ b/test/testframe.c
@@ -643,7 +643,7 @@ TestAlarmOn(void)
/* Get the alarm value from the environment variable, if set */
if (env_val != NULL)
- alarm_sec = (unsigned)HDstrtoul(env_val, (char **)NULL, 10);
+ alarm_sec = (unsigned)strtoul(env_val, (char **)NULL, 10);
/* Set the number of seconds before alarm goes off */
alarm((unsigned)alarm_sec);
diff --git a/test/use_common.c b/test/use_common.c
index 68b7d00..e77ec77 100644
--- a/test/use_common.c
+++ b/test/use_common.c
@@ -94,7 +94,7 @@ parse_option(int argc, char *const argv[], options_t *opts)
} /* end switch (reader/writer-only mode toggle) */
break;
case 'n': /* number of planes to write/read */
- if ((opts->nplanes = HDstrtoul(optarg, NULL, 0)) <= 0) {
+ if ((opts->nplanes = strtoul(optarg, NULL, 0)) <= 0) {
fprintf(stderr, "bad number of planes %s, must be a positive integer\n", optarg);
usage(opts->progname);
Hgoto_error(-1);
@@ -110,7 +110,7 @@ parse_option(int argc, char *const argv[], options_t *opts)
opts->use_swmr = (hbool_t)use_swmr;
break;
case 'y': /* Number of planes per chunk */
- if ((opts->chunkplanes = HDstrtoul(optarg, NULL, 0)) <= 0) {
+ if ((opts->chunkplanes = strtoul(optarg, NULL, 0)) <= 0) {
fprintf(stderr, "bad number of planes per chunk %s, must be a positive integer\n",
optarg);
usage(opts->progname);
@@ -118,7 +118,7 @@ parse_option(int argc, char *const argv[], options_t *opts)
}
break;
case 'z': /* size of chunk=(z,z) */
- if ((opts->chunksize = HDstrtoull(optarg, NULL, 0)) <= 0) {
+ if ((opts->chunksize = strtoull(optarg, NULL, 0)) <= 0) {
fprintf(stderr, "bad chunksize %s, must be a positive integer\n", optarg);
usage(opts->progname);
Hgoto_error(-1);
diff --git a/testpar/t_subfiling_vfd.c b/testpar/t_subfiling_vfd.c
index 99edfe1..9fc7f9b 100644
--- a/testpar/t_subfiling_vfd.c
+++ b/testpar/t_subfiling_vfd.c
@@ -2073,13 +2073,13 @@ parse_subfiling_env_vars(void)
char *env_value;
if (NULL != (env_value = HDgetenv(H5FD_SUBFILING_STRIPE_SIZE))) {
- stripe_size_g = HDstrtoll(env_value, NULL, 0);
+ stripe_size_g = strtoll(env_value, NULL, 0);
if ((ERANGE == errno) || (stripe_size_g <= 0))
stripe_size_g = -1;
}
if (NULL != (env_value = HDgetenv(H5FD_SUBFILING_IOC_PER_NODE))) {
- ioc_per_node_g = HDstrtol(env_value, NULL, 0);
+ ioc_per_node_g = strtol(env_value, NULL, 0);
if ((ERANGE == errno) || (ioc_per_node_g <= 0))
ioc_per_node_g = -1;
else if (ioc_per_node_g * num_nodes_g > mpi_size)
diff --git a/tools/lib/h5tools_utils.c b/tools/lib/h5tools_utils.c
index 983d4af..717ab12 100644
--- a/tools/lib/h5tools_utils.c
+++ b/tools/lib/h5tools_utils.c
@@ -211,7 +211,7 @@ parse_hsize_list(const char *h_list, subset_d *d)
for (ptr = h_list; i < size_count && ptr && *ptr && *ptr != ';' && *ptr != ']'; ptr++)
if (HDisdigit(*ptr)) {
/* we should have an integer now */
- p_list[i++] = (hsize_t)HDstrtoull(ptr, NULL, 0);
+ p_list[i++] = (hsize_t)strtoull(ptr, NULL, 0);
while (HDisdigit(*ptr))
/* scroll to end of integer */
@@ -999,7 +999,7 @@ h5tools_getenv_update_hyperslab_bufsize(void)
/* check if environment variable is set for the hyperslab buffer size */
if (NULL != (env_str = HDgetenv("H5TOOLS_BUFSIZE"))) {
errno = 0;
- hyperslab_bufsize_mb = HDstrtol(env_str, (char **)NULL, 10);
+ hyperslab_bufsize_mb = strtol(env_str, (char **)NULL, 10);
if (errno != 0 || hyperslab_bufsize_mb <= 0)
H5TOOLS_GOTO_ERROR(FAIL, "hyperslab buffer size failed");
@@ -1283,7 +1283,7 @@ h5tools_parse_hdfs_fapl_tuple(const char *tuple_str, int delim, H5FD_hdfs_fapl_t
HDstrncpy(fapl_config_out->user_name, (const char *)props[3], HDstrlen(props[3]));
}
if (HDstrncmp(props[4], "", 1)) {
- k = HDstrtoul((const char *)props[4], NULL, 0);
+ k = strtoul((const char *)props[4], NULL, 0);
if (errno == ERANGE)
H5TOOLS_GOTO_ERROR(FAIL, "supposed buffersize number wasn't");
fapl_config_out->stream_buffer_size = (int32_t)k;
diff --git a/tools/src/h5diff/h5diff_common.c b/tools/src/h5diff/h5diff_common.c
index f941d00..0e34bc4 100644
--- a/tools/src/h5diff/h5diff_common.c
+++ b/tools/src/h5diff/h5diff_common.c
@@ -305,7 +305,7 @@ parse_command_line(int argc, const char *const *argv, const char **fname1, const
usage();
h5diff_exit(EXIT_FAILURE);
}
- opts->count = HDstrtoull(H5_optarg, NULL, 0);
+ opts->count = strtoull(H5_optarg, NULL, 0);
break;
case 'N':
@@ -390,7 +390,7 @@ parse_command_line(int argc, const char *const *argv, const char **fname1, const
if (opts->vfd_info[0].u.name && !HDstrcmp(opts->vfd_info[0].u.name, "onion")) {
if (opts->vfd_info[0].info) {
errno = 0;
- onion_fa_g_1.revision_num = HDstrtoull(opts->vfd_info[0].info, NULL, 10);
+ onion_fa_g_1.revision_num = strtoull(opts->vfd_info[0].info, NULL, 10);
if (errno == ERANGE) {
printf("Invalid onion revision specified for file 1\n");
usage();
@@ -407,7 +407,7 @@ parse_command_line(int argc, const char *const *argv, const char **fname1, const
if (opts->vfd_info[1].u.name && !HDstrcmp(opts->vfd_info[1].u.name, "onion")) {
if (opts->vfd_info[1].info) {
errno = 0;
- onion_fa_g_2.revision_num = HDstrtoull(opts->vfd_info[1].info, NULL, 10);
+ onion_fa_g_2.revision_num = strtoull(opts->vfd_info[1].info, NULL, 10);
if (errno == ERANGE) {
printf("Invalid onion revision specified for file 2\n");
usage();
diff --git a/tools/src/h5dump/h5dump.c b/tools/src/h5dump/h5dump.c
index 9fdaaca..31671b0 100644
--- a/tools/src/h5dump/h5dump.c
+++ b/tools/src/h5dump/h5dump.c
@@ -1238,7 +1238,7 @@ end_collect:
get_onion_revision_count = TRUE;
else {
errno = 0;
- onion_fa_g.revision_num = HDstrtoull(vfd_info_g.info, NULL, 10);
+ onion_fa_g.revision_num = strtoull(vfd_info_g.info, NULL, 10);
if (errno == ERANGE) {
printf("Invalid onion revision specified\n");
goto error;
diff --git a/tools/src/h5import/h5import.c b/tools/src/h5import/h5import.c
index 06a160b..f5197f7 100644
--- a/tools/src/h5import/h5import.c
+++ b/tools/src/h5import/h5import.c
@@ -212,7 +212,7 @@ main(int argc, char *argv[])
break;
case 14: /* read data size */
- if (getInputSize(in, (int)HDstrtol(argv[i], NULL, BASE_10)) == -1) {
+ if (getInputSize(in, (int)strtol(argv[i], NULL, BASE_10)) == -1) {
(void)fprintf(stderr, err8, argv[i]);
goto err;
}
@@ -600,7 +600,7 @@ readIntegerData(FILE *strm, struct Input *in)
(void)fprintf(stderr, "%s", err1);
return (-1);
}
- *in64 = (H5DT_INT64)HDstrtoll(buffer, NULL, 10);
+ *in64 = (H5DT_INT64)strtoll(buffer, NULL, 10);
}
break;
@@ -767,7 +767,7 @@ readUIntegerData(FILE *strm, struct Input *in)
(void)fprintf(stderr, "%s", err1);
return (-1);
}
- *in64 = (H5DT_UINT64)HDstrtoll(buffer, NULL, 10);
+ *in64 = (H5DT_UINT64)strtoll(buffer, NULL, 10);
}
break;
@@ -1570,7 +1570,7 @@ processConfigurationFile(char *infile, struct Input *in)
#endif
if (HDstrcmp("H5T_VARIABLE;", temp) != 0) {
char *more = temp;
- ival = (int)HDstrtol(more, &more, 10);
+ ival = (int)strtol(more, &more, 10);
if (getInputSize(in, ival) == -1) {
(void)fprintf(stderr, err5b, infile);
goto error;
@@ -1669,7 +1669,7 @@ processConfigurationFile(char *infile, struct Input *in)
#endif
while (get_next_dim) {
char *more = temp;
- temp_dims[icount] = HDstrtoull(more, &more, 10);
+ temp_dims[icount] = strtoull(more, &more, 10);
if (HDfscanf(strm, "%254s", temp) != 1) { /* Dimension or end paren */
(void)fprintf(stderr, err6b, infile);
goto error;
@@ -1758,7 +1758,7 @@ processConfigurationFile(char *infile, struct Input *in)
}
else {
char *more = temp;
- in->maxsizeOfDimension[i] = HDstrtoull(more, &more, 10);
+ in->maxsizeOfDimension[i] = strtoull(more, &more, 10);
}
if (HDfscanf(strm, "%254s", temp) != 1) { /* max dim or end paren */
(void)fprintf(stderr, err16c, infile);
@@ -1845,7 +1845,7 @@ processConfigurationFile(char *infile, struct Input *in)
#endif
while (get_next_dim) {
char *more = temp;
- in->sizeOfChunk[icount] = HDstrtoull(more, &more, 10);
+ in->sizeOfChunk[icount] = strtoull(more, &more, 10);
if (HDfscanf(strm, "%254s", temp) != 1) { /* Dimension or end paren */
(void)fprintf(stderr, err6b, infile);
goto error;
@@ -2030,7 +2030,7 @@ processConfigurationFile(char *infile, struct Input *in)
#endif
while (get_next_dim) {
char *more = temp;
- temp_dims[icount] = HDstrtoull(more, &more, 10);
+ temp_dims[icount] = strtoull(more, &more, 10);
if (HDfscanf(strm, "%254s", temp) != 1) { /* Dimension or end paren */
(void)fprintf(stderr, err6b, infile);
goto error;
@@ -2086,7 +2086,7 @@ processConfigurationFile(char *infile, struct Input *in)
#endif
while (get_next_dim) {
char *more = temp;
- temp_dims[icount] = HDstrtoull(more, &more, 10);
+ temp_dims[icount] = strtoull(more, &more, 10);
if (HDfscanf(strm, "%254s", temp) != 1) { /* Dimension or end paren */
(void)fprintf(stderr, err6b, infile);
goto error;
@@ -2573,13 +2573,13 @@ parseDimensions(struct Input *in, char *strm)
i = 0;
HDstrncpy(temp, strm, sizeof(temp));
temp[sizeof(temp) - 1] = '\0';
- in->sizeOfDimension[i++] = HDstrtoull(HDstrtok(temp, delimiter), NULL, BASE_10);
+ in->sizeOfDimension[i++] = strtoull(HDstrtok(temp, delimiter), NULL, BASE_10);
while (1) {
token = HDstrtok(NULL, delimiter);
if (token == NULL)
break;
- in->sizeOfDimension[i++] = HDstrtoull(token, NULL, BASE_10);
+ in->sizeOfDimension[i++] = strtoull(token, NULL, BASE_10);
}
return (0);
}
diff --git a/tools/src/h5ls/h5ls.c b/tools/src/h5ls/h5ls.c
index 2a826c1..24bb345 100644
--- a/tools/src/h5ls/h5ls.c
+++ b/tools/src/h5ls/h5ls.c
@@ -2535,7 +2535,7 @@ get_width(void)
/* Try to get it from the COLUMNS environment variable first since it's
* value is sometimes wrong. */
if ((s = HDgetenv("COLUMNS")) && *s && isdigit((int)*s))
- width = (int)HDstrtol(s, NULL, 0);
+ width = (int)strtol(s, NULL, 0);
#if defined(H5_HAVE_STRUCT_VIDEOCONFIG) && defined(H5_HAVE__GETVIDEOCONFIG)
{
@@ -2784,7 +2784,7 @@ main(int argc, char *argv[])
vfd_info.info = (const void *)(argv[argno] + 11);
}
else if (!HDstrncmp(argv[argno], "--width=", (size_t)8)) {
- width_g = (int)HDstrtol(argv[argno] + 8, &rest, 0);
+ width_g = (int)strtol(argv[argno] + 8, &rest, 0);
if (0 == width_g)
no_line_wrap_g = TRUE;
@@ -2801,7 +2801,7 @@ main(int argc, char *argv[])
else {
s = argv[++argno];
}
- width_g = (int)HDstrtol(s, &rest, 0);
+ width_g = (int)strtol(s, &rest, 0);
if (width_g <= 0 || *rest) {
usage();
leave(EXIT_FAILURE);
@@ -2828,7 +2828,7 @@ main(int argc, char *argv[])
else {
s = argv[++argno];
}
- width_g = (int)HDstrtol(s, &rest, 0);
+ width_g = (int)strtol(s, &rest, 0);
if (0 == width_g) {
no_line_wrap_g = TRUE;
diff --git a/tools/src/h5perf/pio_perf.c b/tools/src/h5perf/pio_perf.c
index 4682f2d..3e306df 100644
--- a/tools/src/h5perf/pio_perf.c
+++ b/tools/src/h5perf/pio_perf.c
@@ -1503,7 +1503,7 @@ parse_size_directive(const char *size)
off_t s;
char *endptr;
- s = HDstrtol(size, &endptr, 10);
+ s = strtol(size, &endptr, 10);
if (endptr && *endptr) {
while (*endptr != '\0' && (*endptr == ' ' || *endptr == '\t'))
diff --git a/tools/src/h5perf/sio_engine.c b/tools/src/h5perf/sio_engine.c
index 9fbe9eb..cc4a28e 100644
--- a/tools/src/h5perf/sio_engine.c
+++ b/tools/src/h5perf/sio_engine.c
@@ -1190,7 +1190,7 @@ set_vfd(parameters *param)
/* Family of files, each 1MB and using the default driver */
/* if ((val=HDstrtok(NULL, " \t\n\r")))
- fam_size = (hsize_t)(HDstrtod(val, NULL) * 1024*1024); */
+ fam_size = (hsize_t)(strtod(val, NULL) * 1024*1024); */
if (H5Pset_fapl_family(my_fapl, fam_size, H5P_DEFAULT) < 0)
return -1;
}
diff --git a/tools/src/h5perf/sio_perf.c b/tools/src/h5perf/sio_perf.c
index 3aad24e..b456a4f 100644
--- a/tools/src/h5perf/sio_perf.c
+++ b/tools/src/h5perf/sio_perf.c
@@ -1175,7 +1175,7 @@ parse_size_directive(const char *size)
hsize_t s;
char *endptr;
- s = HDstrtoull(size, &endptr, 10);
+ s = strtoull(size, &endptr, 10);
if (endptr && *endptr) {
while (*endptr != '\0' && (*endptr == ' ' || *endptr == '\t'))
diff --git a/tools/src/h5repack/h5repack_main.c b/tools/src/h5repack/h5repack_main.c
index 15b206e..7134865 100644
--- a/tools/src/h5repack/h5repack_main.c
+++ b/tools/src/h5repack/h5repack_main.c
@@ -598,7 +598,7 @@ parse_command_line(int argc, const char *const *argv, pack_opt_t *options)
break;
case 'm':
- options->min_comp = HDstrtoull(H5_optarg, NULL, 0);
+ options->min_comp = strtoull(H5_optarg, NULL, 0);
if ((int)options->min_comp <= 0) {
error_msg("invalid minimum compress size <%s>\n", H5_optarg);
h5tools_setstatus(EXIT_FAILURE);
@@ -712,7 +712,7 @@ parse_command_line(int argc, const char *const *argv, pack_opt_t *options)
break;
case 'a':
- options->alignment = HDstrtoull(H5_optarg, NULL, 0);
+ options->alignment = strtoull(H5_optarg, NULL, 0);
if (options->alignment < 1) {
error_msg("invalid alignment size `%s`\n", H5_optarg);
h5tools_setstatus(EXIT_FAILURE);
@@ -759,7 +759,7 @@ parse_command_line(int argc, const char *const *argv, pack_opt_t *options)
break;
case 'G':
- options->fs_pagesize = HDstrtoll(H5_optarg, NULL, 0);
+ options->fs_pagesize = strtoll(H5_optarg, NULL, 0);
if (options->fs_pagesize == 0)
/* To distinguish the "specified" zero value */
options->fs_pagesize = -1;
@@ -890,7 +890,7 @@ parse_command_line(int argc, const char *const *argv, pack_opt_t *options)
if (in_vfd_info.u.name && !HDstrcmp(in_vfd_info.u.name, "onion")) {
if (in_vfd_info.info) {
errno = 0;
- onion_fa_in_g.revision_num = HDstrtoull(in_vfd_info.info, NULL, 10);
+ onion_fa_in_g.revision_num = strtoull(in_vfd_info.info, NULL, 10);
if (errno == ERANGE) {
printf("Invalid onion revision specified for the input file\n");
usage(h5tools_getprogname());
diff --git a/tools/src/h5repack/h5repack_parse.c b/tools/src/h5repack/h5repack_parse.c
index ad1f852..38f9d3b 100644
--- a/tools/src/h5repack/h5repack_parse.c
+++ b/tools/src/h5repack/h5repack_parse.c
@@ -228,15 +228,15 @@ parse_filter(const char *str, unsigned *n_objs, filter_info_t *filt, pack_opt_t
l = 0;
}
else if (f == -1) {
- filt->filt_flag = (unsigned)HDstrtoul(stype, NULL, 0);
+ filt->filt_flag = (unsigned)strtoul(stype, NULL, 0);
f = 0;
}
else if (p == -1) {
- filt->cd_nelmts = HDstrtoull(stype, NULL, 0);
+ filt->cd_nelmts = strtoull(stype, NULL, 0);
p = 0;
}
else {
- filt->cd_values[j++] = (unsigned)HDstrtoul(stype, NULL, 0);
+ filt->cd_values[j++] = (unsigned)strtoul(stype, NULL, 0);
}
q = 0;
u++; /* skip ',' */
@@ -279,7 +279,7 @@ parse_filter(const char *str, unsigned *n_objs, filter_info_t *filt, pack_opt_t
stype[m] = '\0';
} /*if */
- filt->cd_values[j++] = (unsigned)HDstrtoul(stype, NULL, 0);
+ filt->cd_values[j++] = (unsigned)strtoul(stype, NULL, 0);
if (filt->cd_nelmts == 0)
j = 0;
i += m; /* jump */
@@ -596,7 +596,7 @@ parse_layout(const char *str, unsigned *n_objs, pack_info_t *pack, /* info about
if (c == 'x') {
sdim[k - 1] = '\0';
k = 0;
- pack->chunk.chunk_lengths[c_index] = HDstrtoull(sdim, NULL, 0);
+ pack->chunk.chunk_lengths[c_index] = strtoull(sdim, NULL, 0);
if (pack->chunk.chunk_lengths[c_index] == 0) {
if (obj_list)
free(obj_list);
@@ -612,7 +612,7 @@ parse_layout(const char *str, unsigned *n_objs, pack_info_t *pack, /* info about
pack->chunk.rank = -2;
}
else {
- pack->chunk.chunk_lengths[c_index] = HDstrtoull(sdim, NULL, 0);
+ pack->chunk.chunk_lengths[c_index] = strtoull(sdim, NULL, 0);
if (pack->chunk.chunk_lengths[c_index] == 0) {
if (obj_list)
free(obj_list);
diff --git a/tools/src/misc/h5debug.c b/tools/src/misc/h5debug.c
index 0f841a9..7196fbc 100644
--- a/tools/src/misc/h5debug.c
+++ b/tools/src/misc/h5debug.c
@@ -321,7 +321,7 @@ main(int argc, char *argv[])
/* Primary data structure to dump */
if (argc > 2)
- addr = (haddr_t)HDstrtoll(argv[2], NULL, 0);
+ addr = (haddr_t)strtoll(argv[2], NULL, 0);
/* Extra arguments for primary data structure */
HDmemset(extra, 0, sizeof(extra));
@@ -337,7 +337,7 @@ main(int argc, char *argv[])
} /* end if */
for (u = 0; u < (size_t)extra_count; u++)
- extra[u] = (haddr_t)HDstrtoll(argv[u + 3], NULL, 0);
+ extra[u] = (haddr_t)strtoll(argv[u + 3], NULL, 0);
} /* end if */
/*
diff --git a/tools/src/misc/h5repart.c b/tools/src/misc/h5repart.c
index 17c3a97..57b5ea5 100644
--- a/tools/src/misc/h5repart.c
+++ b/tools/src/misc/h5repart.c
@@ -97,14 +97,14 @@ get_size(const char *progname, int *argno, int argc, char *argv[])
char *suffix = NULL;
if (isdigit((int)(argv[*argno][2]))) {
- retval = HDstrtol(argv[*argno] + 2, &suffix, 10);
+ retval = strtol(argv[*argno] + 2, &suffix, 10);
(*argno)++;
}
else if (argv[*argno][2] || *argno + 1 >= argc) {
usage(progname);
}
else {
- retval = HDstrtol(argv[*argno + 1], &suffix, 0);
+ retval = strtol(argv[*argno + 1], &suffix, 0);
if (suffix == argv[*argno + 1])
usage(progname);
*argno += 2;
diff --git a/tools/test/perform/zip_perf.c b/tools/test/perform/zip_perf.c
index 7527716..a21bfd8 100644
--- a/tools/test/perform/zip_perf.c
+++ b/tools/test/perform/zip_perf.c
@@ -280,7 +280,7 @@ parse_size_directive(const char *size)
unsigned long s;
char *endptr;
- s = HDstrtoul(size, &endptr, 10);
+ s = strtoul(size, &endptr, 10);
if (endptr && *endptr) {
while (*endptr != '\0' && (*endptr == ' ' || *endptr == '\t'))
@@ -495,7 +495,7 @@ main(int argc, char *argv[])
min_buf_size = parse_size_directive(H5_optarg);
break;
case 'c':
- compress_percent = (int)HDstrtol(H5_optarg, NULL, 10);
+ compress_percent = (int)strtol(H5_optarg, NULL, 10);
if (compress_percent < 0)
compress_percent = 0;