From: Victor Julien Date: Fri, 6 May 2016 17:44:54 +0000 (+0200) Subject: stream-tcp: fix ssn returning to wrong thread pool X-Git-Tag: suricata-3.1.2~34 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=199bb3bae3cc40ebb87fb0c8cc21bd7b951be678;p=thirdparty%2Fsuricata.git stream-tcp: fix ssn returning to wrong thread pool --- diff --git a/src/stream-tcp.c b/src/stream-tcp.c index c339a0b264..72fb4eda9b 100644 --- a/src/stream-tcp.c +++ b/src/stream-tcp.c @@ -228,7 +228,11 @@ void StreamTcpSessionClear(void *ssnptr) StreamTcpSessionCleanup(ssn); + /* HACK: don't loose track of thread id */ + PoolThreadReserved a = ssn->res; memset(ssn, 0, sizeof(TcpSession)); + ssn->res = a; + PoolThreadReturn(ssn_pool, ssn); #ifdef DEBUG SCMutexLock(&ssn_pool_mutex);