CODA: Proper cleanup of CodaDevice in codagdbadapter

This commit is contained in:
Pawel Polanski
2011-03-08 16:13:09 +01:00
parent 5ad4ea6074
commit 18c4b4bcbf

View File

@@ -1036,7 +1036,7 @@ void CodaGdbAdapter::startAdapter()
QSharedPointer<QTcpSocket> codaSocket; QSharedPointer<QTcpSocket> codaSocket;
if (parameters.communicationChannel == if (parameters.communicationChannel ==
DebuggerStartParameters::CommunicationChannelTcpIp) { DebuggerStartParameters::CommunicationChannelTcpIp) {
m_codaDevice = QSharedPointer<CodaDevice>(new CodaDevice); m_codaDevice = QSharedPointer<CodaDevice>(new CodaDevice, &CodaDevice::deleteLater);
setupTrkDeviceSignals(); setupTrkDeviceSignals();
codaSocket = QSharedPointer<QTcpSocket>(new QTcpSocket); codaSocket = QSharedPointer<QTcpSocket>(new QTcpSocket);
m_codaDevice->setDevice(codaSocket); m_codaDevice->setDevice(codaSocket);