diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2018-03-11 23:34:26 +0100 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2018-03-11 23:34:26 +0100 |
| commit | ae6c3801292c0279a6263ce2b363d0719a0737da (patch) | |
| tree | 50a5a97c6e1a1e2aaabc19eeacee9a6d9082bdff /view.c | |
| parent | d0efde07da335310b2e9da3bb9a690c2123fbc5e (diff) | |
| download | vis-ae6c3801292c0279a6263ce2b363d0719a0737da.tar.gz vis-ae6c3801292c0279a6263ce2b363d0719a0737da.tar.xz | |
view: properly advance over incomplete unicode sequence
When fetching more text we have to skip the bytes processed by the
previous cell, otherwise we end up in an infinite loop.
Diffstat (limited to 'view.c')
| -rw-r--r-- | view.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -360,7 +360,7 @@ void view_draw(View *view) { * wide character. advance file position and read * another junk into buffer. */ - rem = text_bytes_get(view->text, pos, size, text); + rem = text_bytes_get(view->text, pos+prev_cell.len, size, text); text[rem] = '\0'; cur = text; continue; |
