From 989127e525794da87629287a26553f212e3a7388 Mon Sep 17 00:00:00 2001 From: sin Date: Mon, 9 Feb 2015 16:10:00 +0000 Subject: [PATCH] tail: Skip leading spaces in tail -n " +20" --- tail.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tail.c b/tail.c index 2265bac..984de9c 100644 --- a/tail.c +++ b/tail.c @@ -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: