aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDag-Erling Smørgrav <des@FreeBSD.org>2026-07-13 06:42:40 +0000
committerDag-Erling Smørgrav <des@FreeBSD.org>2026-07-13 06:42:40 +0000
commit9fc14dbe4897c4541113b9ba98236fbd7eb75380 (patch)
tree34bffc17d844fd98e5069214b7838603bca35281
parent0f1718e0d588375d6ab6be52f5253fe143c5c75f (diff)
tail: Allow repetitive or contraditory options
Unlike its GNU counterpart, our tail(1) has always errored out if given repetitive or contradictory options, even prior to Keith Bostic's 1991 reimplementation. There is no good reason to continue to do so, not even tradition, since many other commands (including head(1)) simply apply the rightmost option in cases like this. MFC after: 1 week Reviewed by: allanjude, markj Differential Revision: https://reviews.freebsd.org/D58192
-rw-r--r--usr.bin/tail/tail.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/usr.bin/tail/tail.c b/usr.bin/tail/tail.c
index a92eee3881b4..1d76cc59ad61 100644
--- a/usr.bin/tail/tail.c
+++ b/usr.bin/tail/tail.c
@@ -96,8 +96,6 @@ main(int argc, char *argv[])
*/
#define ARG(units, forward, backward) { \
int64_t num; \
- if (style) \
- usage(); \
if (expand_number(optarg, &num)) \
err(1, "illegal offset -- %s", optarg); \
if (num > INT64_MAX / units || num < INT64_MIN / units) \