aboutsummaryrefslogtreecommitdiff
path: root/test/helpers.lua
diff options
context:
space:
mode:
authorLW <git@llllvvuu.dev>2023-11-03 15:56:45 -0700
committerGitHub <noreply@github.com>2023-11-04 06:56:45 +0800
commit468292dcb743c79714b030557cf2754b7b5bf07d (patch)
treeaa7b9a309c68222b0e8d1af2f7fb90c07024df2f /test/helpers.lua
parent9ad239690fe6b151afe2f43c2858d68a2b877e1d (diff)
downloadrneovim-468292dcb743c79714b030557cf2754b7b5bf07d.tar.gz
rneovim-468292dcb743c79714b030557cf2754b7b5bf07d.tar.bz2
rneovim-468292dcb743c79714b030557cf2754b7b5bf07d.zip
fix(rpc): "grid_line" event parsing crashes (#25581)
refactor: use a more idiomatic loop to iterate over the cells There are two cases in which the following assertion would fail: ```c assert(g->icell < g->ncells); ``` 1. If `g->ncells = 0`. Update this to be legal. 2. If an EOF is reached while parsing `wrap`. In this case, the unpacker attempts to resume from `cells`, which is a bug. Create a new state for parsing `wrap`. Reference: https://neovim.io/doc/user/ui.html#ui-event-grid_line
Diffstat (limited to 'test/helpers.lua')
-rw-r--r--test/helpers.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/helpers.lua b/test/helpers.lua
index 02192e4924..f9405c011d 100644
--- a/test/helpers.lua
+++ b/test/helpers.lua
@@ -15,6 +15,7 @@ local function shell_quote(str)
end
end
+--- @class test.helpers
local module = {
REMOVE_THIS = {},
}