diff options
author | Denys Vlasenko | 2010-04-06 23:33:28 +0200 |
---|---|---|
committer | Denys Vlasenko | 2010-04-06 23:33:28 +0200 |
commit | 1854bc1aa2081b99490bd60721122d28fc8a6737 (patch) | |
tree | d05aefe1299f48dbebdf124301c5097d1e4f83ea /util-linux/hexdump.c | |
parent | 64827a2e5dc20a6113e4dc1b96e0f528eeb7fffb (diff) | |
download | busybox-1854bc1aa2081b99490bd60721122d28fc8a6737.zip busybox-1854bc1aa2081b99490bd60721122d28fc8a6737.tar.gz |
hexdump: make -s 0xNNNNN work
function old new delta
hexdump_main 603 605 +2
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux/hexdump.c')
-rw-r--r-- | util-linux/hexdump.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/util-linux/hexdump.c b/util-linux/hexdump.c index f3878f4..2eb5e57 100644 --- a/util-linux/hexdump.c +++ b/util-linux/hexdump.c @@ -92,8 +92,8 @@ int hexdump_main(int argc, char **argv) if (ch == 'n') { dumper->dump_length = xatoi_u(optarg); } /* else */ - if (ch == 's') { - dumper->dump_skip = xatoul_range_sfx(optarg, 0, LONG_MAX, suffixes); + if (ch == 's') { /* compat: -s accepts hex numbers too */ + dumper->dump_skip = xstrtoul_range_sfx(optarg, /*base:*/ 0, /*lo:*/ 0, /*hi:*/ LONG_MAX, suffixes); } /* else */ if (ch == 'v') { dumper->dump_vflag = ALL; |