diff options
author | Denis Vlasenko | 2006-11-27 14:44:18 +0000 |
---|---|---|
committer | Denis Vlasenko | 2006-11-27 14:44:18 +0000 |
commit | 459903bd4e270ab4884ba9577516f9b2753898b0 (patch) | |
tree | 8dd4e8a4db28561fad1dcaeabee936a3aad7187c /coreutils/head.c | |
parent | d686a045c8134d3a42fa5cc6b2e09118e08d603f (diff) | |
download | busybox-459903bd4e270ab4884ba9577516f9b2753898b0.zip busybox-459903bd4e270ab4884ba9577516f9b2753898b0.tar.gz |
Provide our own isdigit macro. saves more than 400 bytes.
Diffstat (limited to 'coreutils/head.c')
-rw-r--r-- | coreutils/head.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/coreutils/head.c b/coreutils/head.c index d732461..f2c9483 100644 --- a/coreutils/head.c +++ b/coreutils/head.c @@ -49,9 +49,8 @@ int head_main(int argc, char **argv) #if !ENABLE_DEBUG_YANK_SUSv2 || ENABLE_FEATURE_FANCY_HEAD /* Allow legacy syntax of an initial numeric option without -n. */ - if ((argc > 1) && (argv[1][0] == '-') - /* && (isdigit)(argv[1][1]) */ - && (((unsigned int)(argv[1][1] - '0')) <= 9) + if (argc > 1 && argv[1][0] == '-' + && isdigit(argv[1][1]) ) { --argc; ++argv; |