Fix behavior of connection_pending event

It is now really only raised when Bro is terminating. Also adds a
test-case that raises the event.
This commit is contained in:
Johanna Amann 2016-07-26 15:48:47 -07:00
parent 743e563dd9
commit 93db6cd876
3 changed files with 9 additions and 1 deletions

View file

@ -355,7 +355,7 @@ void TCP_Analyzer::Done()
{
Analyzer::Done();
if ( connection_pending && is_active && ! BothClosed() )
if ( connection_pending && is_active && ! BothClosed() && terminating )
Event(connection_pending);
LOOP_OVER_GIVEN_CHILDREN(i, packet_children)