summaryrefslogtreecommitdiff
path: root/src/ex_cmds2.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-07-11 22:41:15 +0200
committerBram Moolenaar <Bram@vim.org>2016-07-11 22:41:15 +0200
commit1436d8d51cce114be56209924fc71376407e5bad (patch)
treec6ba6f27b14db303429e2e50ce3645ed865a765c /src/ex_cmds2.c
parentda3a77d9ec28407b8fa2aa014e76944d0a525662 (diff)
downloadvim-git-1436d8d51cce114be56209924fc71376407e5bad.tar.gz
patch 7.4.2026v7.4.2026
Problem: Reference counting for callbacks isn't right. Solution: Add free_callback(). (Ken Takata) Fix reference count.
Diffstat (limited to 'src/ex_cmds2.c')
-rw-r--r--src/ex_cmds2.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/ex_cmds2.c b/src/ex_cmds2.c
index c8980b44b..2b2d63549 100644
--- a/src/ex_cmds2.c
+++ b/src/ex_cmds2.c
@@ -1121,8 +1121,7 @@ remove_timer(timer_T *timer)
static void
free_timer(timer_T *timer)
{
- vim_free(timer->tr_callback);
- partial_unref(timer->tr_partial);
+ free_callback(timer->tr_callback, timer->tr_partial);
vim_free(timer);
}