Commit Diff


commit - e72902bba471f4cc79a683874c7db184aa503fd6
commit + 16482c3bbedc26df5938c248bd58d6240a58d38d
blob - 1cbc6ae5885a908a83e7a349831a28636c3cf536
blob + 8c006114915a340b1e713f721df76ce714d2b538
--- tog/tog.c
+++ tog/tog.c
@@ -476,7 +476,7 @@ draw_commits(struct commit_queue_entry **last, struct 
 }
 
 static void
-scroll_up(struct commit_queue_entry **first_displayed_entry, int n,
+scroll_up(struct commit_queue_entry **first_displayed_entry, int maxscroll,
     struct commit_queue *commits)
 {
 	struct commit_queue_entry *entry;
@@ -487,7 +487,7 @@ scroll_up(struct commit_queue_entry **first_displayed_
 		return;
 
 	entry = *first_displayed_entry;
-	while (entry && nscrolled < n) {
+	while (entry && nscrolled < maxscroll) {
 		entry = TAILQ_PREV(entry, commit_queue, entry);
 		if (entry) {
 			*first_displayed_entry = entry;
@@ -497,7 +497,7 @@ scroll_up(struct commit_queue_entry **first_displayed_
 }
 
 static const struct got_error *
-scroll_down(struct commit_queue_entry **first_displayed_entry, int n,
+scroll_down(struct commit_queue_entry **first_displayed_entry, int maxscroll,
     struct commit_queue_entry *last_displayed_entry,
     struct commit_queue *commits, struct got_repository *repo)
 {
@@ -538,7 +538,7 @@ scroll_down(struct commit_queue_entry **first_displaye
 				last_displayed_entry = pentry;
 			}
 		}
-	} while (++nscrolled < n);
+	} while (++nscrolled < maxscroll);
 
 	return NULL;
 }