From bfc2e5d1d1c98f97eeb089f844fdb6170c654f23 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Wed, 27 Apr 2016 10:20:21 +0200 Subject: text-motions: fix character next motion within a line --- text-motions.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'text-motions.c') diff --git a/text-motions.c b/text-motions.c index e48dd9a..1bf6611 100644 --- a/text-motions.c +++ b/text-motions.c @@ -284,8 +284,7 @@ size_t text_line_char_next(Text *txt, size_t pos) { Iterator it = text_iterator_get(txt, pos); if (!text_iterator_byte_get(&it, &c) || c == '\r' || c == '\n') return pos; - if (!text_iterator_char_next(&it, &c) || c == '\r' || c == '\n') - return pos; + text_iterator_char_next(&it, NULL); return it.pos; } -- cgit v1.2.3