diff options
Diffstat (limited to 'miscutils')
-rw-r--r-- | miscutils/fbsplash.c | 2 | ||||
-rw-r--r-- | miscutils/hdparm.c | 4 | ||||
-rw-r--r-- | miscutils/ionice.c | 2 | ||||
-rw-r--r-- | miscutils/makedevs.c | 8 | ||||
-rw-r--r-- | miscutils/mt.c | 2 | ||||
-rw-r--r-- | miscutils/rfkill.c | 2 |
6 files changed, 10 insertions, 10 deletions
diff --git a/miscutils/fbsplash.c b/miscutils/fbsplash.c index e370d20..a031cbd 100644 --- a/miscutils/fbsplash.c +++ b/miscutils/fbsplash.c @@ -311,7 +311,7 @@ static void init(const char *cfg_filename) parser_t *parser = config_open2(cfg_filename, xfopen_stdin); while (config_read(parser, token, 2, 2, "#=", (PARSE_NORMAL | PARSE_MIN_DIE) & ~(PARSE_TRIM | PARSE_COLLAPSE))) { - unsigned val = xatoi_u(token[1]); + unsigned val = xatoi_positive(token[1]); int i = index_in_strings(param_names, token[0]); if (i < 0) bb_error_msg_and_die("syntax error: %s", token[0]); diff --git a/miscutils/hdparm.c b/miscutils/hdparm.c index 236b174..c6ca3af 100644 --- a/miscutils/hdparm.c +++ b/miscutils/hdparm.c @@ -2055,8 +2055,8 @@ int hdparm_main(int argc, char **argv) #if ENABLE_FEATURE_HDPARM_HDIO_SCAN_HWIF if (c == 'R') { scan_hwif = parse_opts_0_INTMAX(&hwif_data); - hwif_ctrl = xatoi_u((argv[optind]) ? argv[optind] : ""); - hwif_irq = xatoi_u((argv[optind+1]) ? argv[optind+1] : ""); + hwif_ctrl = xatoi_positive((argv[optind]) ? argv[optind] : ""); + hwif_irq = xatoi_positive((argv[optind+1]) ? argv[optind+1] : ""); /* Move past the 2 additional arguments */ argv += 2; argc -= 2; diff --git a/miscutils/ionice.c b/miscutils/ionice.c index 52e51b9..6b791c4 100644 --- a/miscutils/ionice.c +++ b/miscutils/ionice.c @@ -73,7 +73,7 @@ int ionice_main(int argc UNUSED_PARAM, char **argv) if (!(opt & (OPT_n|OPT_c))) { if (!(opt & OPT_p) && *argv) - pid = xatoi_u(*argv); + pid = xatoi_positive(*argv); pri = ioprio_get(IOPRIO_WHO_PROCESS, pid); if (pri == -1) diff --git a/miscutils/makedevs.c b/miscutils/makedevs.c index abf5057..0578d92 100644 --- a/miscutils/makedevs.c +++ b/miscutils/makedevs.c @@ -36,10 +36,10 @@ int makedevs_main(int argc, char **argv) basedev = argv[1]; buf = xasprintf("%s%u", argv[1], (unsigned)-1); type = argv[2]; - Smajor = xatoi_u(argv[3]); - Sminor = xatoi_u(argv[4]); - S = xatoi_u(argv[5]); - E = xatoi_u(argv[6]); + Smajor = xatoi_positive(argv[3]); + Sminor = xatoi_positive(argv[4]); + S = xatoi_positive(argv[5]); + E = xatoi_positive(argv[6]); nodname = argv[7] ? basedev : buf; mode = 0660; diff --git a/miscutils/mt.c b/miscutils/mt.c index 586373d..8df2b75 100644 --- a/miscutils/mt.c +++ b/miscutils/mt.c @@ -106,7 +106,7 @@ int mt_main(int argc UNUSED_PARAM, char **argv) op.mt_op = opcode_value[idx]; if (argv[2]) - op.mt_count = xatoi_u(argv[2]); + op.mt_count = xatoi_positive(argv[2]); else op.mt_count = 1; /* One, not zero, right? */ diff --git a/miscutils/rfkill.c b/miscutils/rfkill.c index 0f5817b..7d8ad1c 100644 --- a/miscutils/rfkill.c +++ b/miscutils/rfkill.c @@ -53,7 +53,7 @@ int rfkill_main(int argc UNUSED_PARAM, char **argv) rf_name = "uwb"; rf_type = index_in_strings(rfkill_types, rf_name); if (rf_type < 0) { - rf_idx = xatoi_u(rf_name); + rf_idx = xatoi_positive(rf_name); } } |