summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-09-17 14:09:56 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-09-17 14:09:56 +0100
commitcf76bbb67ab921f5c0b8b2a770c56a49e2707147 (patch)
treef6a850eb3f5aa69c9c5d6019f17e833609fb1ca7
parent623acd70ca98b8257bb90c463bcc5ba5d76ec99b (diff)
downloadrspamd-cf76bbb67ab921f5c0b8b2a770c56a49e2707147.tar.gz
rspamd-cf76bbb67ab921f5c0b8b2a770c56a49e2707147.zip
[Minor] Fix some minor issues
-rw-r--r--lualib/lua_selectors.lua2
-rw-r--r--src/libserver/re_cache.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/lualib/lua_selectors.lua b/lualib/lua_selectors.lua
index c42d53b24..3a7a3207f 100644
--- a/lualib/lua_selectors.lua
+++ b/lualib/lua_selectors.lua
@@ -66,7 +66,7 @@ uses any type by default)]],
},
['rcpts'] = {
['get_value'] = function(task, args)
- local rcpts = task:get_rcpt(args[1] or 0)
+ local rcpts = task:get_recipients(args[1] or 0)
if ((rcpts or E)[1] or E).addr then
return rcpts,'email_list'
end
diff --git a/src/libserver/re_cache.c b/src/libserver/re_cache.c
index 707d220ce..64f53773d 100644
--- a/src/libserver/re_cache.c
+++ b/src/libserver/re_cache.c
@@ -865,7 +865,7 @@ rspamd_re_cache_process_selector (struct rspamd_task *task,
*lenvec = g_malloc (sizeof (guint) * (*n));
for (guint i = 0; i < *n; i ++) {
- lua_rawgeti (L, -2, i + 1);
+ lua_rawgeti (L, -1, i + 1);
(*svec)[i] = g_strdup (lua_tolstring (L, -1, &slen));
(*lenvec)[i] = slen;
lua_pop (L, 1);