Added connected clients tracking to BlockingTCPAcceptor. For each new connection a new 'BlockingServerTCPTransport' object is created, but was never released.
The acceptor now stores all the objects in a set, and registers a callback with the client, to be notified when the connection is closed. On notification the client is them removed from the set and the memory is released. When the acceptor is destroyed, it also closes and deleted all the connected clients.
This commit is contained in:
@@ -208,7 +208,8 @@ namespace epics {
|
||||
}
|
||||
|
||||
void BlockingTCPTransport::internalClose(bool force) {
|
||||
// noop
|
||||
// close the socket
|
||||
epicsSocketDestroy(_channel);
|
||||
}
|
||||
|
||||
int BlockingTCPTransport::getSocketReceiveBufferSize() const {
|
||||
|
||||
Reference in New Issue
Block a user