Ssh: fix crash on freed memory access

At the cleanup() method we must remove connection from the m_connection
list to avoid access to the freed memory from the
removeInactiveConnections() that caused Qt Creator crash.

Change-Id: I8195f05e903819e3e3b48b2f72fd71047c5a1636
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
Alexander Drozdov
2022-01-27 20:14:17 +10:00
parent 161d25571b
commit 5c53dc5e13

View File

@@ -151,6 +151,7 @@ private:
disconnect(connection, nullptr, this, nullptr);
connection->deleteLater();
m_connections.erase(it);
}
void removeInactiveConnections()