Skip to content

Commit c7053e5

Browse files
author
Felipe Zimmerle
committed
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.
1 parent 4d03ef5 commit c7053e5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/rule.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -697,7 +697,7 @@ bool Rule::evaluate(Transaction *trans,
697697

698698
end_exec:
699699
executeActionsAfterFullMatch(trans, containsDisruptive, ruleMessage);
700-
if (this->m_chained == false && ruleMessage->m_saveMessage != false) {
700+
if (m_ruleId != 0 && ruleMessage->m_saveMessage != false) {
701701
trans->serverLog(ruleMessage);
702702
trans->m_rulesMessages.push_back(*ruleMessage);
703703
}

0 commit comments

Comments
 (0)