aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2012-02-18 15:36:40 +0100
committerLuke Dashjr <luke-jr+git@utopios.org>2012-02-27 12:36:56 -0500
commitcaad1add4f383960ca09bb466ddd16652245befe (patch)
tree640d53b40461d6ba7544a37a846a75766c51e8d6
parent69ce70866d7498eb6efadca0cf57785c5cefd386 (diff)
downloadbitcoin-caad1add4f383960ca09bb466ddd16652245befe.tar.xz
Free pwalletdbEncryption after encryping wallet
Fixes a memory leak.
-rw-r--r--src/wallet.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wallet.cpp b/src/wallet.cpp
index 43fb6b6da3..9f7422d1fb 100644
--- a/src/wallet.cpp
+++ b/src/wallet.cpp
@@ -183,7 +183,7 @@ bool CWallet::EncryptWallet(const string& strWalletPassphrase)
if (!pwalletdbEncryption->TxnCommit())
exit(1); //We now have keys encrypted in memory, but no on disk...die to avoid confusion and let the user reload their unencrypted wallet.
- pwalletdbEncryption->Close();
+ delete pwalletdbEncryption;
pwalletdbEncryption = NULL;
}