* Now uses the new wait_for_timer() stack function on destruction - this fixes

bug #2143.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26981 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2008-08-15 14:47:11 +00:00
parent 9e8be8bb9c
commit c5e91552e1
@@ -406,7 +406,8 @@ TCPEndpoint::TCPEndpoint(net_socket* socket)
this);
gStackModule->init_timer(&fDelayedAcknowledgeTimer,
TCPEndpoint::_DelayedAcknowledgeTimer, this);
gStackModule->init_timer(&fTimeWaitTimer, TCPEndpoint::_TimeWaitTimer, this);
gStackModule->init_timer(&fTimeWaitTimer, TCPEndpoint::_TimeWaitTimer,
this);
}
@@ -424,8 +425,11 @@ TCPEndpoint::~TCPEndpoint()
mutex_destroy(&fLock);
// TODO: we need to wait for all timers to return
//_WaitForTimers();
// we need to wait for all timers to return
gStackModule->wait_for_timer(&fRetransmitTimer);
gStackModule->wait_for_timer(&fPersistTimer);
gStackModule->wait_for_timer(&fDelayedAcknowledgeTimer);
gStackModule->wait_for_timer(&fTimeWaitTimer);
}