diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2016-12-30 19:52:44 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2016-12-30 19:52:44 +0000 |
commit | 334371d02881053dd91927691c663dc4c19fe0fc (patch) | |
tree | c78e1795d470250686ee8da4d49824644a285c2d /usr.bin/less/linenum.c | |
parent | 4c1572700749c37f305ff2cd7c31a939e73e18c2 (diff) |
restore a not so redundant test. loopcount = -1 is a significant indicator
to prevent printing the calculating message over and over.
from Hugo Villeneuve
Diffstat (limited to 'usr.bin/less/linenum.c')
-rw-r--r-- | usr.bin/less/linenum.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/less/linenum.c b/usr.bin/less/linenum.c index 299657a93a3..48672e9f2ac 100644 --- a/usr.bin/less/linenum.c +++ b/usr.bin/less/linenum.c @@ -202,7 +202,7 @@ static time_t startime; static void longish(void) { - if (++loopcount > 100) { + if (loopcount >= 0 && ++loopcount > 100) { loopcount = 0; if (time(NULL) >= startime + LONGTIME) { ierror("Calculating line numbers", NULL); |