tail: Skip leading spaces in tail -n " +20"

This commit is contained in:
sin 2015-02-09 16:10:00 +00:00
parent fe3fc41838
commit 989127e525

2
tail.c
View File

@ -75,7 +75,7 @@ main(int argc, char *argv[])
case 'n':
lines = EARGF(usage());
n = MIN(llabs(estrtonum(lines, LLONG_MIN + 1, MIN(LLONG_MAX, SIZE_MAX))), SIZE_MAX);
if (lines[0] == '+')
if (strchr(lines, '+'))
tail = dropinit;
break;
ARGNUM: