Commit ed2c5ac2f0de61c0755db8d9eec8eefdf2f1fc70

Stefan Sperling 2019-02-22T00:03:51

tog: don't try to load more commits in scroll_down() if log is done

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/tog/tog.c b/tog/tog.c
index acba3bc..a286666 100644
--- a/tog/tog.c
+++ b/tog/tog.c
@@ -1204,7 +1204,7 @@ scroll_down(struct commit_queue_entry **first_displayed_entry, int maxscroll,
 
 	do {
 		pentry = TAILQ_NEXT(*last_displayed_entry, entry);
-		if (pentry == NULL) {
+		if (pentry == NULL && !*log_complete) {
 			*commits_needed = maxscroll + 20;
 			while (*commits_needed > 0) {
 				int errcode;