diff options
| author | Ricky Zhou <rickyz@google.com> | 2023-06-01 02:15:14 -0700 |
|---|---|---|
| committer | Ricky Zhou <rickyz@google.com> | 2023-06-05 22:34:55 -0700 |
| commit | 981acc2922ce9a5f214ba14acbb1e444748855f2 (patch) | |
| tree | 6316a11d19f9f63adf7ffd6dbc585600c7b36c45 /src/nvim/msgpack_rpc/unpacker.c | |
| parent | 780ab11b90119fb9b91d3266d6eef459228edc9a (diff) | |
| download | rneovim-981acc2922ce9a5f214ba14acbb1e444748855f2.tar.gz rneovim-981acc2922ce9a5f214ba14acbb1e444748855f2.tar.bz2 rneovim-981acc2922ce9a5f214ba14acbb1e444748855f2.zip | |
fix(ui): propagate line wrapping state on grid_line events
This fixes the TUI's line-wrapping behavior, which was broken with the
migration to the msgpack-based UI protocol (see
https://github.com/neovim/neovim/issues/7369#issuecomment-1571812273).
Diffstat (limited to 'src/nvim/msgpack_rpc/unpacker.c')
| -rw-r--r-- | src/nvim/msgpack_rpc/unpacker.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/nvim/msgpack_rpc/unpacker.c b/src/nvim/msgpack_rpc/unpacker.c index 25edf2e21d..4128f91b6e 100644 --- a/src/nvim/msgpack_rpc/unpacker.c +++ b/src/nvim/msgpack_rpc/unpacker.c @@ -441,7 +441,7 @@ redo: case 14: NEXT_TYPE(tok, MPACK_TOKEN_ARRAY); int eventarrsize = (int)tok.length; - if (eventarrsize != 4) { + if (eventarrsize != 5) { p->state = -1; return false; } @@ -509,11 +509,16 @@ redo: } g->icell++; - p->read_ptr = data; - p->read_size = size; if (g->icell == g->ncells) { + NEXT_TYPE(tok, MPACK_TOKEN_BOOLEAN); + g->wrap = mpack_unpack_boolean(tok); + p->read_ptr = data; + p->read_size = size; return true; } + + p->read_ptr = data; + p->read_size = size; goto redo; case 12: |