commit 1ef6803: [Minor] Set processed stage when called from Lua
Vsevolod Stakhov
vsevolod at highsecure.ru
Sat Oct 12 09:07:05 UTC 2019
Author: Vsevolod Stakhov
Date: 2019-10-12 10:01:31 +0100
URL: https://github.com/rspamd/rspamd/commit/1ef680311f90018518d43bae992f1aacb5ae9222
[Minor] Set processed stage when called from Lua
---
src/lua/lua_task.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/src/lua/lua_task.c b/src/lua/lua_task.c
index 4293ef178..c3159f16b 100644
--- a/src/lua/lua_task.c
+++ b/src/lua/lua_task.c
@@ -1330,8 +1330,14 @@ lua_task_process_message (lua_State *L)
if (task != NULL) {
if (task->msg.len > 0) {
if (rspamd_message_parse (task)) {
- lua_pushboolean (L, TRUE);
- rspamd_message_process (task);
+ if (!(task->flags & RSPAMD_TASK_FLAG_SKIP_PROCESS)) {
+ lua_pushboolean (L, TRUE);
+ rspamd_message_process (task);
+ task->processed_stages |= RSPAMD_TASK_STAGE_PROCESS_MESSAGE;
+ }
+ else {
+ lua_pushboolean (L, FALSE);
+ }
}
else {
lua_pushboolean (L, FALSE);
More information about the Commits
mailing list