diff options
author | Famiu Haque <famiuhaque@protonmail.com> | 2022-09-02 17:44:14 +0600 |
---|---|---|
committer | Famiu Haque <famiuhaque@protonmail.com> | 2022-09-02 17:49:51 +0600 |
commit | 2dd55f81f736d5fe9697cd0e15c96f763eb90458 (patch) | |
tree | c82a101a98ce697925993bdcfbc5c10a264d6845 /src | |
parent | ce80b8f50d7d56ac12aa06a64a65799ec18b69af (diff) | |
download | rneovim-2dd55f81f736d5fe9697cd0e15c96f763eb90458.tar.gz rneovim-2dd55f81f736d5fe9697cd0e15c96f763eb90458.tar.bz2 rneovim-2dd55f81f736d5fe9697cd0e15c96f763eb90458.zip |
fix(ui): ui compositor does not correctly free event callbacks
Prior to this PR, when freeing event callbacks, UI compositor did not
free the luarefs which could cause potential memory leaks. This PR fixes
that by freeing the luarefs properly.
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/ui_compositor.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/ui_compositor.c b/src/nvim/ui_compositor.c index b8c7834e2b..2fb70eae8a 100644 --- a/src/nvim/ui_compositor.c +++ b/src/nvim/ui_compositor.c @@ -98,7 +98,7 @@ void ui_comp_free_all_mem(void) { UIEventCallback *event_cb; map_foreach_value(&ui_event_cbs, event_cb, { - xfree(event_cb); + free_ui_event_callback(event_cb); }) pmap_destroy(uint32_t)(&ui_event_cbs); } |