From 4521de2dfd334074d83e730c82a39e2590a06de5 Mon Sep 17 00:00:00 2001 From: Eric Leblond Date: Mon, 24 Jun 2013 09:58:42 +0200 Subject: [PATCH] Use PACKET_* macro instead of UPDATE Setting the ACTION_DROP flag can be done via PACKET_DROP instead of using PACKET_UPDATE_ACTION. --- src/detect.c | 2 +- src/stream-tcp.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/detect.c b/src/detect.c index d297b55300..1e39710156 100644 --- a/src/detect.c +++ b/src/detect.c @@ -1342,7 +1342,7 @@ int SigMatchSignatures(ThreadVars *th_v, DetectEngineCtx *de_ctx, DetectEngineTh if (p->flow->flags & FLOW_ACTION_DROP) { alert_flags = PACKET_ALERT_FLAG_DROP_FLOW; - PACKET_UPDATE_ACTION(p, ACTION_DROP); + PACKET_DROP(p); } } diff --git a/src/stream-tcp.c b/src/stream-tcp.c index aa96de3abe..1aee65c480 100644 --- a/src/stream-tcp.c +++ b/src/stream-tcp.c @@ -4165,7 +4165,7 @@ static int StreamTcpPacket (ThreadVars *tv, Packet *p, StreamTcpThread *stt, FlowSetNoPacketInspectionFlag(p->flow); DecodeSetNoPacketInspectionFlag(p); FlowSetSessionNoApplayerInspectionFlag(p->flow); - PACKET_UPDATE_ACTION(p, ACTION_DROP); + PACKET_DROP(p); /* return the segments to the pool */ StreamTcpSessionPktFree(p); SCReturnInt(0); @@ -4377,7 +4377,7 @@ error: } if (StreamTcpInlineMode()) { - PACKET_UPDATE_ACTION(p, ACTION_DROP); + PACKET_DROP(p); } SCReturnInt(-1); }