aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/autocmd.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/autocmd.c')
-rw-r--r--src/nvim/autocmd.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/nvim/autocmd.c b/src/nvim/autocmd.c
index d51079b515..d364881084 100644
--- a/src/nvim/autocmd.c
+++ b/src/nvim/autocmd.c
@@ -18,6 +18,7 @@
#include "nvim/ex_getln.h"
#include "nvim/fileio.h"
#include "nvim/getchar.h"
+#include "nvim/insexpand.h"
#include "nvim/lua/executor.h"
#include "nvim/map.h"
#include "nvim/option.h"
@@ -2051,8 +2052,8 @@ static bool call_autocmd_callback(const AutoCmd *ac, const AutoPatCmd *apc)
break;
}
- FIXED_TEMP_ARRAY(args, 1);
- args.items[0] = DICTIONARY_OBJ(data);
+ MAXSIZE_TEMP_ARRAY(args, 1);
+ ADD_C(args, DICTIONARY_OBJ(data));
Object result = nlua_call_ref(callback.data.luaref, NULL, args, true, NULL);
if (result.type == kObjectTypeBoolean) {