aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_async.lua
diff options
context:
space:
mode:
authorVolodymyr Chernetskyi <volodymyr_chernetskyi@goodyear.com>2026-09-05 02:57:55 +0200
committerGitHub <noreply@github.com>2026-09-04 20:57:55 -0400
commit48864161cd75ae4b58f7af94d6c9add0ba876107 (patch)
tree357a165969bca4198afa43fa95981385d7bd68ce /runtime/lua/vim/_async.lua
parent3a02a399578c9063807f8e327697095a1a5923ce (diff)
downloadrneovim-48864161cd75ae4b58f7af94d6c9add0ba876107.tar.gz
rneovim-48864161cd75ae4b58f7af94d6c9add0ba876107.tar.bz2
rneovim-48864161cd75ae4b58f7af94d6c9add0ba876107.zip
fix(api): leaked error message in nvim_win_set_buf() #41688
Problem: Both handle lookups write into the same `Error` before either one is checked, and `api_set_error()` unconditionally `xmalloc`s `err->msg` without freeing what is already there. When both handles are invalid, the message allocated for the window is silently overwritten by the one for the buffer and leaked. Solution: Check the window before looking up the buffer. As a side effect the reported error no longer names the buffer when the window was wrong too. AI-assisted
Diffstat (limited to 'runtime/lua/vim/_async.lua')
0 files changed, 0 insertions, 0 deletions