diff --git a/usr.bin/tail/forward.c b/usr.bin/tail/forward.c index f1f111840839..ffca06a93b17 100644 --- a/usr.bin/tail/forward.c +++ b/usr.bin/tail/forward.c @@ -302,7 +302,7 @@ rlines(fp, off, sbp) } /* Set the file pointer to reflect the length displayed. */ - if (fseek(fp, 0L, SEEK_END) == -1) { + if (fseeko(fp, sbp->st_size, SEEK_SET) == -1) { ierr(); return; }