diff options
author | João Barbosa <joao.paulo.barbosa@gmail.com> | 2019-01-29 00:06:17 +0000 |
---|---|---|
committer | João Barbosa <joao.paulo.barbosa@gmail.com> | 2019-02-03 22:23:43 +0000 |
commit | 60e190ceb3563a8102d42fdfcbefccdd1b53e812 (patch) | |
tree | 67dac9dbfa8c1c5f24606d6fd9a855c0aca87687 /src/qt/bitcoin.cpp | |
parent | 2fbf6a57d282d80c128c910dd1fcdd0ee0542654 (diff) |
gui: Fix WalletController deletion
The wallet controller instanced must be deleted after the window instance
since it is used there.
Diffstat (limited to 'src/qt/bitcoin.cpp')
-rw-r--r-- | src/qt/bitcoin.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp index ca26131b95..0f06bbaaa6 100644 --- a/src/qt/bitcoin.cpp +++ b/src/qt/bitcoin.cpp @@ -218,6 +218,8 @@ BitcoinApplication::~BitcoinApplication() #ifdef ENABLE_WALLET delete paymentServer; paymentServer = nullptr; + delete m_wallet_controller; + m_wallet_controller = nullptr; #endif delete optionsModel; optionsModel = nullptr; @@ -310,10 +312,6 @@ void BitcoinApplication::requestShutdown() window->setClientModel(nullptr); pollShutdownTimer->stop(); -#ifdef ENABLE_WALLET - delete m_wallet_controller; - m_wallet_controller = nullptr; -#endif delete clientModel; clientModel = nullptr; |