diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-05-24 19:55:37 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2018-05-24 19:56:05 +0100 |
commit | 25ef6b98215f5518dae638ce0fd6b4710f17b113 (patch) | |
tree | 3bd032e2097a3e65985bb10d1ae926498011086f /src/rspamadm/confighelp.c | |
parent | bb638f7c7d851f20071f5f9ee77224c0173e73ae (diff) | |
download | rspamd-25ef6b98215f5518dae638ce0fd6b4710f17b113.tar.gz rspamd-25ef6b98215f5518dae638ce0fd6b4710f17b113.zip |
[Project] Rework rspamadm and Lua init path
Diffstat (limited to 'src/rspamadm/confighelp.c')
-rw-r--r-- | src/rspamadm/confighelp.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/rspamadm/confighelp.c b/src/rspamadm/confighelp.c index 8f208b805..7ce72dea9 100644 --- a/src/rspamadm/confighelp.c +++ b/src/rspamadm/confighelp.c @@ -30,9 +30,11 @@ extern struct rspamd_main *rspamd_main; extern module_t *modules[]; extern worker_t *workers[]; -static void rspamadm_confighelp (gint argc, gchar **argv); +static void rspamadm_confighelp (gint argc, gchar **argv, + const struct rspamadm_command *cmd); -static const char *rspamadm_confighelp_help (gboolean full_help); +static const char *rspamadm_confighelp_help (gboolean full_help, + const struct rspamadm_command *cmd); struct rspamadm_command confighelp_command = { .name = "confighelp", @@ -55,7 +57,7 @@ static GOptionEntry entries[] = { }; static const char * -rspamadm_confighelp_help (gboolean full_help) +rspamadm_confighelp_help (gboolean full_help, const struct rspamadm_command *cmd) { const char *help_str; @@ -189,7 +191,7 @@ rspamadm_confighelp_search_word (const ucl_object_t *obj, const gchar *str) } static void -rspamadm_confighelp (gint argc, gchar **argv) +rspamadm_confighelp (gint argc, gchar **argv, const struct rspamadm_command *cmd) { struct rspamd_config *cfg; ucl_object_t *doc_obj; @@ -224,7 +226,8 @@ rspamadm_confighelp (gint argc, gchar **argv) pworker++; } - cfg = rspamd_config_new (); + cfg = rspamd_config_new (RSPAMD_CONFIG_INIT_SKIP_LUA); + cfg->lua_state = L; cfg->compiled_modules = modules; cfg->compiled_workers = workers; |