Fix use after free in LanLinkProvider::connectError()
If QSslSocket::connectToHost() hasn't finished running. Thanks Matthias Gerstner <mgerstner@suse.de> for reporting this.
This commit is contained in:
parent
b279c52101
commit
d35b88c1b2
1 changed files with 1 additions and 1 deletions
|
@ -252,7 +252,7 @@ void LanLinkProvider::connectError(QAbstractSocket::SocketError socketError)
|
|||
//The socket we created didn't work, and we didn't manage
|
||||
//to create a LanDeviceLink from it, deleting everything.
|
||||
delete m_receivedIdentityPackets.take(socket).np;
|
||||
delete socket;
|
||||
socket->deleteLater();
|
||||
}
|
||||
|
||||
//We received a UDP packet and answered by connecting to them by TCP. This gets called on a successful connection.
|
||||
|
|
Loading…
Reference in a new issue