]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Fix some minor issues
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 17 Sep 2018 13:09:56 +0000 (14:09 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Mon, 17 Sep 2018 13:09:56 +0000 (14:09 +0100)
lualib/lua_selectors.lua
src/libserver/re_cache.c

index c42d53b244b289f0baa9a68d89b2f4bd0f103efc..3a7a3207f29efa3e050021fd5696d52a2386bfa8 100644 (file)
@@ -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
index 707d220ce1bc45b984df87432519b767c97f155b..64f53773d25631902623fb9eeb5bfa558ac0f654 100644 (file)
@@ -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);