summaryrefslogtreecommitdiffstats
path: root/src/lua/lua_common.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-02-16 16:50:05 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-02-16 16:50:05 +0000
commit8518faa83e19f31ab9a08eeaabb770c185422a7e (patch)
tree4c7039d243fc40ae781e2f65203d7a606e52b960 /src/lua/lua_common.c
parent195bfd320c83a04728faf213b38346b18b28d5a0 (diff)
downloadrspamd-8518faa83e19f31ab9a08eeaabb770c185422a7e.tar.gz
rspamd-8518faa83e19f31ab9a08eeaabb770c185422a7e.zip
Do not set lua path when cfg is not loaded.
Diffstat (limited to 'src/lua/lua_common.c')
-rw-r--r--src/lua/lua_common.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lua/lua_common.c b/src/lua/lua_common.c
index 78a80f1ea..cb5f07712 100644
--- a/src/lua/lua_common.c
+++ b/src/lua/lua_common.c
@@ -351,8 +351,6 @@ rspamd_lua_init (struct rspamd_config *cfg)
rspamd_lua_add_preload (L, "ucl", luaopen_ucl);
- rspamd_lua_set_path (L, cfg);
-
return L;
}
@@ -395,6 +393,7 @@ rspamd_init_lua_filters (struct rspamd_config *cfg)
struct script_module *module;
lua_State *L = cfg->lua_state;
+ rspamd_lua_set_path (L, cfg);
cur = g_list_first (cfg->script_modules);
while (cur) {