Destructor crash fix
This commit is contained in:
parent
5776ca0384
commit
5ae9873455
2 changed files with 6 additions and 6 deletions
|
@ -123,9 +123,9 @@ UiLogic::~UiLogic()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
m_vpnConnection->deleteLater();
|
||||||
m_vpnConnectionThread.quit();
|
m_vpnConnectionThread.quit();
|
||||||
m_vpnConnectionThread.wait(3000);
|
m_vpnConnectionThread.wait(3000);
|
||||||
delete m_vpnConnection;
|
|
||||||
|
|
||||||
qDebug() << "Application closed";
|
qDebug() << "Application closed";
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,16 +26,16 @@
|
||||||
#include "utils.h"
|
#include "utils.h"
|
||||||
#include "vpnconnection.h"
|
#include "vpnconnection.h"
|
||||||
|
|
||||||
VpnConnection::VpnConnection(QObject* parent) : QObject(parent)
|
VpnConnection::VpnConnection(QObject* parent) : QObject(parent),
|
||||||
{
|
m_settings(this)
|
||||||
|
|
||||||
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
VpnConnection::~VpnConnection()
|
VpnConnection::~VpnConnection()
|
||||||
{
|
{
|
||||||
//qDebug() << "VpnConnection::~VpnConnection() 1";
|
m_vpnProtocol->deleteLater();
|
||||||
m_vpnProtocol.clear();
|
m_vpnProtocol.clear();
|
||||||
//qDebug() << "VpnConnection::~VpnConnection() 2";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void VpnConnection::onBytesChanged(quint64 receivedBytes, quint64 sentBytes)
|
void VpnConnection::onBytesChanged(quint64 receivedBytes, quint64 sentBytes)
|
||||||
|
@ -220,7 +220,7 @@ void VpnConnection::connectToVpn(int serverIndex,
|
||||||
|
|
||||||
#if !defined (Q_OS_ANDROID) && !defined (Q_OS_IOS)
|
#if !defined (Q_OS_ANDROID) && !defined (Q_OS_IOS)
|
||||||
if (!m_IpcClient) {
|
if (!m_IpcClient) {
|
||||||
m_IpcClient = new IpcClient;
|
m_IpcClient = new IpcClient(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!m_IpcClient->isSocketConnected()) {
|
if (!m_IpcClient->isSocketConnected()) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue