git: 9fc14dbe4897 - main - tail: Allow repetitive or contraditory options

From: Dag-Erling Smørgrav <des_at_FreeBSD.org>
Date: Mon, 13 Jul 2026 06:42:55 UTC
The branch main has been updated by des:

URL: https://cgit.FreeBSD.org/src/commit/?id=9fc14dbe4897c4541113b9ba98236fbd7eb75380

commit 9fc14dbe4897c4541113b9ba98236fbd7eb75380
Author:     Dag-Erling Smørgrav <des@FreeBSD.org>
AuthorDate: 2026-07-13 06:42:40 +0000
Commit:     Dag-Erling Smørgrav <des@FreeBSD.org>
CommitDate: 2026-07-13 06:42:40 +0000

    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
---
 usr.bin/tail/tail.c | 2 --
 1 file changed, 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)		\