From df48fb456fb6bf63d94cad9b302ff01d8ee8d311 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Fri, 22 Jul 2016 21:50:18 +0200 Subject: patch 7.4.2090 Problem: Using submatch() in a lambda passed to substitute() is verbose. Solution: Use a static list and pass it as an optional argument to the function. Fix memory leak. --- src/ex_cmds2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ex_cmds2.c') diff --git a/src/ex_cmds2.c b/src/ex_cmds2.c index 2b2d63549f..adc53529b4 100644 --- a/src/ex_cmds2.c +++ b/src/ex_cmds2.c @@ -1163,7 +1163,7 @@ timer_callback(timer_T *timer) argv[1].v_type = VAR_UNKNOWN; call_func(timer->tr_callback, (int)STRLEN(timer->tr_callback), - &rettv, 1, argv, 0L, 0L, &dummy, TRUE, + &rettv, 1, argv, NULL, 0L, 0L, &dummy, TRUE, timer->tr_partial, NULL); clear_tv(&rettv); } -- cgit v1.2.3