mirror of
https://github.com/itay-grudev/SingleApplication.git
synced 2024-11-15 20:25:43 +08:00
Merge pull request #125 from dail8859/fix-123
Remove ConnectionInfo after socket is destroyed
This commit is contained in:
commit
e99b8df38f
@ -328,10 +328,11 @@ void SingleApplicationPrivate::slotConnectionEstablished()
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
QObject::connect(nextConnSocket, &QLocalSocket::disconnected,
|
QObject::connect(nextConnSocket, &QLocalSocket::disconnected, nextConnSocket, &QLocalSocket::deleteLater);
|
||||||
|
|
||||||
|
QObject::connect(nextConnSocket, &QLocalSocket::destroyed,
|
||||||
[nextConnSocket, this](){
|
[nextConnSocket, this](){
|
||||||
connectionMap.remove(nextConnSocket);
|
connectionMap.remove(nextConnSocket);
|
||||||
nextConnSocket->deleteLater();
|
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user