GNU bug report logs - #78910
tail does not support -r added by POSIX.1-2024

Previous Next

Package: coreutils;

Reported by: Collin Funk <collin.funk1 <at> gmail.com>

Date: Fri, 27 Jun 2025 05:37:03 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Eric Blake <eblake <at> redhat.com>
To: Bernhard Voelker <mail <at> bernhard-voelker.de>
Cc: Pádraig Brady <P <at> draigbrady.com>, Jim Meyering <jim <at> meyering.net>, 78910 <at> debbugs.gnu.org, Collin Funk <collin.funk1 <at> gmail.com>
Subject: bug#78910: tail does not support -r added by POSIX.1-2024
Date: Tue, 1 Jul 2025 14:37:06 -0500
On Tue, Jul 01, 2025 at 07:07:45PM +0200, Bernhard Voelker wrote:
> On 6/28/25 00:21, Pádraig Brady wrote:
> > I wouldn't be rushing to implement it TBH.
> 
> Furthermore, -r clashes with the existing -f,--follow ... hence it's even more
> surprising that POSIX does not specify what should happen for those logically
> conflicting modes.

Remember, the POSIX synopsis lines lists two distinct invocation
styles:

tail [-f] [-c number|-n number] [file]
tail -r [-n number] [file]

which means undefined behavior from the POSIX point of view if -f and
-r are ever attempted at the same time.  Therefore, whatever GNU
decides to do on that combo (preferably, diagnose it early with an
error and exit, since I can't figure out anything else useful it could
do) will not violate POSIX.

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.
Virtualization:  qemu.org | libguestfs.org





This bug report was last modified 38 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.