Fixed bug where pager(1) prints a line too much.
This commit is contained in:
parent
5e317c9726
commit
a6a296a971
|
@ -80,7 +80,7 @@ int main(int argc, char* argv[])
|
|||
if ( c == '\n' ) { charleft = WIDTH; }
|
||||
bool eol = (c == '\n') || !charleft;
|
||||
if ( eol ) { charleft = WIDTH; }
|
||||
if ( eol && !linesleft )
|
||||
if ( eol && linesleft <= 1 )
|
||||
{
|
||||
printf("\n--pager--");
|
||||
fflush(stdout);
|
||||
|
|
Loading…
Reference in New Issue