diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-10-20 19:07:57 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-10-20 19:07:57 +0100 |
commit | 0f80039eec1f47d882970529124dfe07ad669b9c (patch) | |
tree | 9ce504a5c6ece95988055b58608f9801bba459be /src/lua | |
parent | f9ad1e3300b77a7810234d6567ab94df90850ef2 (diff) | |
download | rspamd-0f80039eec1f47d882970529124dfe07ad669b9c.tar.gz rspamd-0f80039eec1f47d882970529124dfe07ad669b9c.zip |
[Fix] Fix periodic events and redis
Diffstat (limited to 'src/lua')
-rw-r--r-- | src/lua/lua_config.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lua/lua_config.c b/src/lua/lua_config.c index d7ddae802..dc1371013 100644 --- a/src/lua/lua_config.c +++ b/src/lua/lua_config.c @@ -1994,7 +1994,7 @@ lua_periodic_callback (gint unused_fd, short what, gpointer ud) struct timeval tv; struct rspamd_lua_periodic *periodic = ud; struct rspamd_config **pcfg; - struct ev_base **pev_base; + struct event_base **pev_base; lua_State *L; gboolean plan_more = FALSE; @@ -2005,6 +2005,7 @@ lua_periodic_callback (gint unused_fd, short what, gpointer ud) *pcfg = periodic->cfg; pev_base = lua_newuserdata (L, sizeof (*pev_base)); rspamd_lua_setclass (L, "rspamd{ev_base}", -1); + *pev_base = periodic->ev_base; if (lua_pcall (L, 2, 1, 0) != 0) { msg_info ("call to periodic failed: %s", lua_tostring (L, -1)); |