diff options
author | Alan Coopersmith <alan.coopersmith@sun.com> | 2009-09-23 23:12:08 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@sun.com> | 2009-09-23 23:12:08 -0700 |
commit | 032e3cb6c41c720412ab3403dad2ab800f45a817 (patch) | |
tree | c7a45c0ab940a6ada137129c5e435b76375e3aef | |
parent | ca16bc230e73bfbf651acb9010ba695bbbef0e8a (diff) |
Fix parsing of hexadecimal arguments to bdftruncate
Since bdftruncate suggests running itself with "0x3200", that should work.
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
-rw-r--r-- | bdftruncate.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bdftruncate.c b/bdftruncate.c index 9bb204b..a527305 100644 --- a/bdftruncate.c +++ b/bdftruncate.c @@ -57,7 +57,7 @@ parse_threshold(const char *str) if (!isdigit((unsigned char)*str)) return 1; - if (str[0] == 0 && (str[1] == 'x' || str[1] == 'X')) + if (str[0] == '0' && (str[1] == 'x' || str[1] == 'X')) base = 16; else base = 10; @@ -140,7 +140,7 @@ main(int argc, char **argv) if (argc != 1 || (opt_plus_w && opt_minus_w)) usage(); if (parse_threshold(*argv)) { - fprintf(stderr, "Illegal threshold %s", *argv); + fprintf(stderr, "Illegal threshold %s\n", *argv); usage(); } |