stream: fix reachable assertion

Fix `Flow::thread_id` not always getting properly set up, leading to
a reachable assertion.

Bug #4582.

(cherry picked from commit b06c0579f5)
pull/7936/head
Victor Julien 4 years ago
parent 21492a419e
commit 3570ec6f6e

@ -4850,8 +4850,6 @@ int StreamTcpPacket (ThreadVars *tv, Packet *p, StreamTcpThread *stt,
SCLogDebug("p->pcap_cnt %"PRIu64, p->pcap_cnt);
HandleThreadId(tv, p, stt);
TcpSession *ssn = (TcpSession *)p->flow->protoctx;
/* track TCP flags */
@ -5275,6 +5273,8 @@ TmEcode StreamTcp (ThreadVars *tv, Packet *p, void *data, PacketQueueNoLock *pq)
return TM_ECODE_OK;
}
HandleThreadId(tv, p, stt);
/* only TCP packets with a flow from here */
if (!(p->flags & PKT_PSEUDO_STREAM_END)) {

Loading…
Cancel
Save