From 839ff03b98de80ba367872f5f6d8cd28e706152b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Manuel=20Tom=C3=A1s?= Date: Wed, 29 Apr 2020 13:25:46 -0300 Subject: Fix prev_line moving too much on long lines --- point.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'point.c') diff --git a/point.c b/point.c index 755b99f..515d73d 100644 --- a/point.c +++ b/point.c @@ -67,7 +67,7 @@ uint64_t rseek(struct point *point, uint8_t c, int limit) { void prev_line(struct point *point, int window_width) { move_point_backward(point); move_point_backward(point); - rseek(point, '\n', window_width); + rseek(point, '\n', window_width - 2); if (element(point) == '\n') { move_point_forward(point); } -- cgit v1.2.3