commit 4aa27c1b145ae6aec83cecc7fc37b9842854b769
Author: Jochen Sprickerhof <[email protected]>
AuthorDate: Wed Apr 15 22:36:40 2020 +0200
Commit: Jochen Sprickerhof <[email protected]>
CommitDate: Wed Apr 15 22:40:24 2020 +0200
Don't print child output while scrolling
diff --git a/scroll.c b/scroll.c
index 720ada1..5752cf8 100644
--- a/scroll.c
+++ b/scroll.c
@@ -520,8 +520,10 @@ main(int argc, char *argv[])
input[n] = '\0';
- if (write(STDOUT_FILENO, input, n) == -1)
- die("write:");
+ /* don't print child output while scrolling */
+ if (bottom == TAILQ_FIRST(&head))
+ if (write(STDOUT_FILENO, input, n) == -1)
+ die("write:");
/* iterate over the input buffer */
for (char *c = input; n-- > 0; c++) {