diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2014-04-30 13:26:51 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2014-04-30 13:26:51 +0100 |
commit | d6643f35d783784911ad2e2ca754bcfed29eb11d (patch) | |
tree | 55554d57d4439e278788a261eb5ad7e5016a1372 /src/lua/lua_common.c | |
parent | 7e66b3bd08dbca9356013a3777f786076d1dacea (diff) | |
download | rspamd-d6643f35d783784911ad2e2ca754bcfed29eb11d.tar.gz rspamd-d6643f35d783784911ad2e2ca754bcfed29eb11d.zip |
Refactor config API.
Diffstat (limited to 'src/lua/lua_common.c')
-rw-r--r-- | src/lua/lua_common.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/lua/lua_common.c b/src/lua/lua_common.c index f7912a722..349cf09b5 100644 --- a/src/lua/lua_common.c +++ b/src/lua/lua_common.c @@ -264,7 +264,7 @@ lua_add_actions_global (lua_State *L) } lua_State * -init_lua (struct config_file *cfg) +init_lua (struct rspamd_config *cfg) { lua_State *L; @@ -306,7 +306,7 @@ init_lua (struct config_file *cfg) * Initialize new locked lua_State structure */ struct lua_locked_state* -init_lua_locked (struct config_file *cfg) +init_lua_locked (struct rspamd_config *cfg) { struct lua_locked_state *new; @@ -334,12 +334,12 @@ free_lua_locked (struct lua_locked_state *st) } gboolean -init_lua_filters (struct config_file *cfg) +init_lua_filters (struct rspamd_config *cfg) { - struct config_file **pcfg; + struct rspamd_config **pcfg; GList *cur, *tmp; struct script_module *module; - struct statfile *st; + struct rspamd_statfile_config *st; lua_State *L = cfg->lua_state; cur = g_list_first (cfg->script_modules); @@ -353,7 +353,7 @@ init_lua_filters (struct config_file *cfg) } /* Initialize config structure */ - pcfg = lua_newuserdata (L, sizeof (struct config_file *)); + pcfg = lua_newuserdata (L, sizeof (struct rspamd_config *)); lua_setclass (L, "rspamd{config}", -1); *pcfg = cfg; lua_setglobal (L, "rspamd_config"); @@ -563,7 +563,7 @@ lua_consolidation_func (struct rspamd_task *task, const gchar *metric_name, cons } double -lua_normalizer_func (struct config_file *cfg, long double score, void *params) +lua_normalizer_func (struct rspamd_config *cfg, long double score, void *params) { GList *p = params; long double res = score; |