aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJaquee <jaquee.monero@gmail.com>2017-10-22 16:15:14 +0200
committerJaquee <jaquee.monero@gmail.com>2017-10-22 16:15:14 +0200
commit913ef54c22180ae71b848537536ea5dc12726269 (patch)
treec3db41b2e8516dfc83f59f49a77a426e2fc7fa35 /src
parentea49e842159b6de5144b0daaf44e37a093817fbe (diff)
downloadmonzero-gui-913ef54c22180ae71b848537536ea5dc12726269.tar.gz
monzero-gui-913ef54c22180ae71b848537536ea5dc12726269.tar.xz
monzero-gui-913ef54c22180ae71b848537536ea5dc12726269.zip
Store cache on exit
Diffstat (limited to 'src')
-rw-r--r--src/libwalletqt/Wallet.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/libwalletqt/Wallet.cpp b/src/libwalletqt/Wallet.cpp
index 5a71debf..fcd0dbae 100644
--- a/src/libwalletqt/Wallet.cpp
+++ b/src/libwalletqt/Wallet.cpp
@@ -643,6 +643,12 @@ Wallet::~Wallet()
delete m_history;
m_history = NULL;
//Monero::WalletManagerFactory::getWalletManager()->closeWallet(m_walletImpl);
+ if(status() == Status_Critical)
+ qDebug("Not storing wallet cache");
+ else if( m_walletImpl->store(""))
+ qDebug("Wallet cache stored successfully");
+ else
+ qDebug("Error storing wallet cache");
delete m_walletImpl;
m_walletImpl = NULL;
qDebug("m_walletImpl deleted");