From 0ae6d8f0d0f16466121c66627afe299555fccb3a Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Tue, 7 Apr 2015 18:20:45 +0100 Subject: Indicies in lua starts from 1. --- src/lua/lua_trie.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/lua/lua_trie.c') diff --git a/src/lua/lua_trie.c b/src/lua/lua_trie.c index 3a07fa3b1..35abdff3d 100644 --- a/src/lua/lua_trie.c +++ b/src/lua/lua_trie.c @@ -134,7 +134,7 @@ lua_trie_callback (int strnum, int textpos, void *context) /* Function */ lua_pushvalue (L, 3); - lua_pushnumber (L, strnum); + lua_pushnumber (L, strnum + 1); lua_pushnumber (L, textpos); if (lua_pcall (L, 2, 1, 0) != 0) { -- cgit v1.2.3