ClientList: use "delete" instead of Client::Close()
Client::Close() installs a TimeoutMonitor, which is not something we should do during shutdown.
This commit is contained in:
parent
c12da599b9
commit
4c705334fa
@ -40,8 +40,14 @@ ClientList::Remove(Client &client)
|
|||||||
void
|
void
|
||||||
ClientList::CloseAll()
|
ClientList::CloseAll()
|
||||||
{
|
{
|
||||||
while (!list.empty())
|
while (!list.empty()) {
|
||||||
list.front()->Close();
|
delete list.front();
|
||||||
|
list.pop_front();
|
||||||
|
|
||||||
|
#ifndef NDEBUG
|
||||||
|
--size;
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
assert(size == 0);
|
assert(size == 0);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user