aboutsummaryrefslogtreecommitdiffstats
path: root/src/lua
diff options
context:
space:
mode:
authorGuillaume Outters <guillaume.outters@free.fr>2017-07-20 02:47:51 +0200
committerGuillaume Outters <guillaume.outters@free.fr>2017-07-20 02:47:51 +0200
commit291e6183a49d5c030e08df92384775a48e05a7ed (patch)
tree8f7b2fc0e77335311b87170f20a529fd5c313da6 /src/lua
parent5d37e69a60b836818823a6c43cb4269d10d82094 (diff)
downloadrspamd-291e6183a49d5c030e08df92384775a48e05a7ed.tar.gz
rspamd-291e6183a49d5c030e08df92384775a48e05a7ed.zip
[Fix] Lua: lpeg to be loaded with rspamd_lua_add_preload, to avoid "rspamd_config_read: rcl parse error: cannot init lua file […] module 'lpeg' not found"
Diffstat (limited to 'src/lua')
-rw-r--r--src/lua/lua_common.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lua/lua_common.c b/src/lua/lua_common.c
index 58c728607..2fde26a31 100644
--- a/src/lua/lua_common.c
+++ b/src/lua/lua_common.c
@@ -334,7 +334,6 @@ rspamd_lua_init ()
luaopen_fann (L);
luaopen_sqlite3 (L);
luaopen_cryptobox (L);
- luaopen_lpeg (L);
luaL_newmetatable (L, "rspamd{ev_base}");
lua_pushstring (L, "class");
@@ -349,6 +348,7 @@ rspamd_lua_init ()
lua_pop (L, 1);
rspamd_lua_new_class (L, "rspamd{worker}", worker_reg);
+ rspamd_lua_add_preload (L, "lpeg", luaopen_lpeg);
rspamd_lua_add_preload (L, "ucl", luaopen_ucl);
/* Add plugins global */