diff options
author | luukvbaal <31730729+luukvbaal@users.noreply.github.com> | 2023-01-17 02:51:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-17 09:51:01 +0800 |
commit | f6929ea51d21034c6ed00d68a727c2c7cd7ec6ac (patch) | |
tree | ed170792a83bb0f4a83e218597944d6cc7cacee4 /test/functional/ui/tabline_spec.lua | |
parent | 6c2f02cbd02e8fd90e8ffae271dad3df48a54c4a (diff) | |
download | rneovim-f6929ea51d21034c6ed00d68a727c2c7cd7ec6ac.tar.gz rneovim-f6929ea51d21034c6ed00d68a727c2c7cd7ec6ac.tar.bz2 rneovim-f6929ea51d21034c6ed00d68a727c2c7cd7ec6ac.zip |
fix(tabline): avoid memory leak in tabline click definitions (#21847)
Problem: Memory is leaked in tabline click definitions since
https://github.com/neovim/neovim/pull/21008.
Solution: Add back a call to `stl_clear_click_defs()` that was lost in
the refactor PR.
Diffstat (limited to 'test/functional/ui/tabline_spec.lua')
-rw-r--r-- | test/functional/ui/tabline_spec.lua | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/ui/tabline_spec.lua b/test/functional/ui/tabline_spec.lua index 0e35a03557..2cdec62d01 100644 --- a/test/functional/ui/tabline_spec.lua +++ b/test/functional/ui/tabline_spec.lua @@ -119,4 +119,10 @@ describe("tabline", function() [2] = {bold = true, foreground = Screen.colors.Blue}; }} end) + + it('click definitions do not leak memory #21765', function() + command('set tabline=%@MyClickFunc@MyClickText%T') + command('set showtabline=2') + command('redrawtabline') + end) end) |