From c7053e572fa6b5103c6a95b7e172bda83f4db39f Mon Sep 17 00:00:00 2001 From: Felipe Zimmerle Date: Wed, 29 Mar 2017 14:51:32 -0300 Subject: [PATCH] Postponing the decision to whenever save or not a log message to the last rule Whenever there is a chained rule, the decision of saving a message on the webserver's log will be taken after the execution of all actions on the chain, including the default actions. --- src/rule.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rule.cc b/src/rule.cc index eb4b749a..946a4e1a 100644 --- a/src/rule.cc +++ b/src/rule.cc @@ -697,7 +697,7 @@ end_clean: end_exec: executeActionsAfterFullMatch(trans, containsDisruptive, ruleMessage); - if (this->m_chained == false && ruleMessage->m_saveMessage != false) { + if (m_ruleId != 0 && ruleMessage->m_saveMessage != false) { trans->serverLog(ruleMessage); trans->m_rulesMessages.push_back(*ruleMessage); }