diff options
| author | Andrew Chow <[email protected]> | 2020-06-15 17:59:24 -0400 |
|---|---|---|
| committer | Andrew Chow <[email protected]> | 2020-07-14 11:07:16 -0400 |
| commit | 27b27663849932971eb5deadb1f19234b9cd97ea (patch) | |
| tree | f8fa0655e170c4c2b1edbc7eaa440cdc101295a7 /src/wallet/wallettool.cpp | |
| parent | Merge #19323: gui: Fix regression in *txoutset* in GUI console (diff) | |
| download | discoin-27b27663849932971eb5deadb1f19234b9cd97ea.tar.xz discoin-27b27663849932971eb5deadb1f19234b9cd97ea.zip | |
walletdb: Move BerkeleyDatabase::Flush(true) to Close()
Instead of having Flush optionally shutdown the database and
environment, add a Close() function that does that.
Diffstat (limited to 'src/wallet/wallettool.cpp')
| -rw-r--r-- | src/wallet/wallettool.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wallet/wallettool.cpp b/src/wallet/wallettool.cpp index 8a45d8145..9f25b1ae7 100644 --- a/src/wallet/wallettool.cpp +++ b/src/wallet/wallettool.cpp @@ -17,7 +17,7 @@ namespace WalletTool { static void WalletToolReleaseWallet(CWallet* wallet) { wallet->WalletLogPrintf("Releasing wallet\n"); - wallet->Flush(true); + wallet->Close(); delete wallet; } @@ -133,7 +133,7 @@ bool ExecuteWalletToolFunc(const std::string& command, const std::string& name) std::shared_ptr<CWallet> wallet_instance = CreateWallet(name, path); if (wallet_instance) { WalletShowInfo(wallet_instance.get()); - wallet_instance->Flush(true); + wallet_instance->Close(); } } else if (command == "info" || command == "salvage") { if (!fs::exists(path)) { @@ -145,7 +145,7 @@ bool ExecuteWalletToolFunc(const std::string& command, const std::string& name) std::shared_ptr<CWallet> wallet_instance = LoadWallet(name, path); if (!wallet_instance) return false; WalletShowInfo(wallet_instance.get()); - wallet_instance->Flush(true); + wallet_instance->Close(); } else if (command == "salvage") { return SalvageWallet(path); } |