Merge in SNORT/snort3 from ~ANOROKH/snort3:rtn_check to master
Squashed commit of the following:
commit
d969e687476e4f6ca453fa0501691e93dd0b8442
Author: AnnaNorokh <annanorokh15@gmail.comm>
Date: Thu Mar 9 16:00:01 2023 +0200
actions: restore rtn check in Actions::alert and add to Actions::log
#include "actions.h"
-#include <cassert>
-
#include "detection/detect.h"
#include "managers/action_manager.h"
#include "parser/parser.h"
void Actions::log(Packet* p, const OptTreeNode* otn)
{
RuleTreeNode* rtn = getRtnFromOtn(otn);
- assert(rtn);
+ if (!rtn)
+ return;
+
CallLogFuncs(p, otn, rtn->listhead);
}
return;
RuleTreeNode* rtn = getRtnFromOtn(otn);
- assert(rtn);
+ if (!rtn)
+ return;
/* Call OptTreeNode specific output functions */
if (otn->outputFuncs)