diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2013-11-29 16:45:45 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2013-11-29 16:45:45 +0100 |
commit | 327f550669a80d72f36bc9e4de619c163aa46eff (patch) | |
tree | d304092aeb06539085be1385ab9298876c414b44 /miscutils/hdparm.c | |
parent | 9b2a9f0210f13f1c59c0b954c4aa0eeb0a66efd1 (diff) | |
download | busybox-w32-327f550669a80d72f36bc9e4de619c163aa46eff.tar.gz busybox-w32-327f550669a80d72f36bc9e4de619c163aa46eff.tar.bz2 busybox-w32-327f550669a80d72f36bc9e4de619c163aa46eff.zip |
Use unsigned printf/scanf conversion where more appropriate
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'miscutils/hdparm.c')
-rw-r--r-- | miscutils/hdparm.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/miscutils/hdparm.c b/miscutils/hdparm.c index 69726ae72..f0e9c9d75 100644 --- a/miscutils/hdparm.c +++ b/miscutils/hdparm.c | |||
@@ -465,14 +465,14 @@ static void on_off(int value) | |||
465 | static void print_flag_on_off(int get_arg, const char *s, unsigned long arg) | 465 | static void print_flag_on_off(int get_arg, const char *s, unsigned long arg) |
466 | { | 466 | { |
467 | if (get_arg) { | 467 | if (get_arg) { |
468 | printf(" setting %s to %ld", s, arg); | 468 | printf(" setting %s to %lu", s, arg); |
469 | on_off(arg); | 469 | on_off(arg); |
470 | } | 470 | } |
471 | } | 471 | } |
472 | 472 | ||
473 | static void print_value_on_off(const char *str, unsigned long argp) | 473 | static void print_value_on_off(const char *str, unsigned long argp) |
474 | { | 474 | { |
475 | printf(" %s\t= %2ld", str, argp); | 475 | printf(" %s\t= %2lu", str, argp); |
476 | on_off(argp != 0); | 476 | on_off(argp != 0); |
477 | } | 477 | } |
478 | 478 | ||
@@ -1509,7 +1509,7 @@ static void bus_state_value(unsigned value) | |||
1509 | else if (value == BUSSTATE_TRISTATE) | 1509 | else if (value == BUSSTATE_TRISTATE) |
1510 | printf(" (tristate)\n"); | 1510 | printf(" (tristate)\n"); |
1511 | else | 1511 | else |
1512 | printf(" (unknown: %d)\n", value); | 1512 | printf(" (unknown: %u)\n", value); |
1513 | } | 1513 | } |
1514 | #endif | 1514 | #endif |
1515 | 1515 | ||
@@ -1589,7 +1589,7 @@ static void interpret_xfermode(unsigned xfermode) | |||
1589 | static void print_flag(int flag, const char *s, unsigned long value) | 1589 | static void print_flag(int flag, const char *s, unsigned long value) |
1590 | { | 1590 | { |
1591 | if (flag) | 1591 | if (flag) |
1592 | printf(" setting %s to %ld\n", s, value); | 1592 | printf(" setting %s to %lu\n", s, value); |
1593 | } | 1593 | } |
1594 | 1594 | ||
1595 | static void process_dev(char *devname) | 1595 | static void process_dev(char *devname) |