From ca98b49813c78cf3aede241c3dea7743c8ecabda Mon Sep 17 00:00:00 2001 From: Jfreegman Date: Wed, 18 Jun 2014 18:29:07 -0400 Subject: [PATCH] fix scrolling bug --- src/line_info.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/line_info.c b/src/line_info.c index a6442f0..177440d 100644 --- a/src/line_info.c +++ b/src/line_info.c @@ -222,7 +222,7 @@ static void line_info_check_queue(ToxWindow *self) /* move line_start forward proportionate to the number of new lines */ if (y + lines - 1 >= max_y) { while (lines > 0 && hst->line_start->next) { - lines -= 1 + hst->line_start->newlines + (hst->line_start->len / (x2 - offst)); + lines -= 1 + hst->line_start->next->newlines + (hst->line_start->next->len / (x2 - offst)); hst->line_start = hst->line_start->next; ++hst->start_id; }