diff options
author | Denis Vlasenko | 2007-05-31 23:55:39 +0000 |
---|---|---|
committer | Denis Vlasenko | 2007-05-31 23:55:39 +0000 |
commit | fdcfa2aba7b804082090c424f11d0cf8cad30405 (patch) | |
tree | d799d69401193de4582467e6645d2c9d14453c07 /miscutils | |
parent | 342b0ab945bb335ead1d23a3bddf9d77fc944f56 (diff) | |
download | busybox-fdcfa2aba7b804082090c424f11d0cf8cad30405.zip busybox-fdcfa2aba7b804082090c424f11d0cf8cad30405.tar.gz |
less: less <HUGEFILE + [End] busy loops, fix it
Diffstat (limited to 'miscutils')
-rw-r--r-- | miscutils/less.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/miscutils/less.c b/miscutils/less.c index 7be634f..9b2c43b 100644 --- a/miscutils/less.c +++ b/miscutils/less.c @@ -347,8 +347,10 @@ static void read_lines(void) } else { flines[max_fline] = xrealloc(current_line, strlen(current_line)+1); } - if (max_fline >= MAXLINES) + if (max_fline >= MAXLINES) { + eof_error = 0; /* Pretend we saw EOF */ break; + } if (max_fline > cur_fline + max_displayed_line) break; if (eof_error <= 0) { |