From 1adad44b7ce6574f505f4cf5df3c8e21c0747f93 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Sun, 5 Mar 2023 16:52:47 +0800 Subject: vim-patch:9.0.0749: alloc/free of buffer for each quickfix entry is inefficient Problem: Alloc/free of buffer for each quickfix entry is inefficient. Solution: Use a shared grow array. (Yegappan Lakshmanan, closes vim/vim#11365) https://github.com/vim/vim/commit/975a665d4811649a51e2c6a97a6ce096290d87ae Co-authored-by: Yegappan Lakshmanan --- src/nvim/memory.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/nvim/memory.c') diff --git a/src/nvim/memory.c b/src/nvim/memory.c index 4e799dfd08..ffeafbdf2c 100644 --- a/src/nvim/memory.c +++ b/src/nvim/memory.c @@ -755,11 +755,7 @@ void free_all_mem(void) p_hi = 0; init_history(); - qf_free_all(NULL); - // Free all location lists - FOR_ALL_TAB_WINDOWS(tab, win) { - qf_free_all(win); - } + free_quickfix(); // Close all script inputs. close_all_scripts(); -- cgit