diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-10-10 17:17:09 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-10-10 17:17:09 +0100 |
commit | 6e31344466e2558a99cd46bb29abaa37e1faffc6 (patch) | |
tree | ae51cd2a56c252d6f0df6755b76719fe121e81e3 /src/rspamadm | |
parent | c4d3eb4af41a17cf28cb4fbb171d9b70d98259b5 (diff) | |
download | rspamd-6e31344466e2558a99cd46bb29abaa37e1faffc6.tar.gz rspamd-6e31344466e2558a99cd46bb29abaa37e1faffc6.zip |
[Minor] Fix compile warnings
Diffstat (limited to 'src/rspamadm')
-rw-r--r-- | src/rspamadm/lua_repl.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/rspamadm/lua_repl.c b/src/rspamadm/lua_repl.c index b7fd9a4d3..ee22c4868 100644 --- a/src/rspamadm/lua_repl.c +++ b/src/rspamadm/lua_repl.c @@ -544,7 +544,7 @@ lua_syntax_highlighter (const char *str, ReplxxColor *colours, int size, void *u * 3 - line num (int), always 1... * 4 - column num (must be less than size) */ - const gchar *what, *text; + const gchar *what; gsize column, tlen, cur_top, elt_pos; ReplxxColor elt_color = REPLXX_COLOR_DEFAULT; @@ -554,7 +554,7 @@ lua_syntax_highlighter (const char *str, ReplxxColor *colours, int size, void *u lua_rawgeti (L, elt_pos, 1); what = lua_tostring (L, -1); lua_rawgeti (L, elt_pos, 2); - text = lua_tolstring (L, -1, &tlen); + lua_tolstring (L, -1, &tlen); lua_rawgeti (L, elt_pos, 4); column = lua_tointeger (L, -1); @@ -782,15 +782,11 @@ rspamadm_lua_handle_exec (struct rspamd_http_connection_entry *conn_ent, GString *tb; gint err_idx, i; lua_State *L; - struct rspamadm_lua_repl_context *ctx; - struct rspamadm_lua_repl_session *session = conn_ent->ud; ucl_object_t *obj, *elt; const gchar *body; gsize body_len; - - ctx = session->ctx; - struct thread_entry *thread = lua_thread_pool_get_for_config (rspamd_main->cfg); + L = thread->lua_state; body = rspamd_http_message_get_body (msg, &body_len); |