threading: fix flow timeout loop race

pull/4383/head
Victor Julien 6 years ago
parent 56354afd41
commit 825173a2ba

@ -217,12 +217,11 @@ static int TmThreadTimeoutLoop(ThreadVars *tv, TmSlot *s)
} }
} }
} else { } else {
SleepUsec(1); if (TmThreadsCheckFlag(tv, THV_KILL)) {
}
if (tv->stream_pq->len == 0 && TmThreadsCheckFlag(tv, THV_KILL)) {
break; break;
} }
SleepUsec(1);
}
} }
SCLogDebug("flow end loop complete"); SCLogDebug("flow end loop complete");

Loading…
Cancel
Save