HomeFreeBSD

tail: fix "tail -r" for piped input that begins with '\n'

Description

tail: fix "tail -r" for piped input that begins with '\n'

A subtle logic bug, probably introduced in r311895, caused tail to print the
first two lines of piped input in forward order, if the very first character
was a newline.

PR: 222671
Reported by: Jim Long <freebsd-bugzilla@umpquanet.com>, pprocacci@gmail.com
MFC after: 3 weeks
Sponsored by: Spectra Logic Corp

Details

Provenance
asomersAuthored on
Parents
rS329605: Commit missing !sys portion of last merge.
Branches
Unknown
Tags
Unknown