]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
flow-worker: improve no-flow case
authorVictor Julien <victor@inliniac.net>
Thu, 1 Jun 2017 13:26:55 +0000 (15:26 +0200)
committerVictor Julien <victor@inliniac.net>
Thu, 1 Jun 2017 13:26:55 +0000 (15:26 +0200)
src/flow-worker.c

index 456720c2dc0561eca5b26b94e941ecfefc1a3bcb..078c991f601d4916b6cb511336ed0f3106b46032 100644 (file)
@@ -198,7 +198,7 @@ static TmEcode FlowWorker(ThreadVars *tv, Packet *p, void *data, PacketQueue *pr
     SCLogDebug("packet %"PRIu64" has flow? %s", p->pcap_cnt, p->flow ? "yes" : "no");
 
     /* handle TCP and app layer */
-    if (PKT_IS_TCP(p)) {
+    if (p->flow && PKT_IS_TCP(p)) {
         SCLogDebug("packet %"PRIu64" is TCP. Direction %s", p->pcap_cnt, PKT_IS_TOSERVER(p) ? "TOSERVER" : "TOCLIENT");
         DEBUG_ASSERT_FLOW_LOCKED(p->flow);