aboutsummaryrefslogtreecommitdiff
path: root/src/wallet
diff options
context:
space:
mode:
Diffstat (limited to 'src/wallet')
-rw-r--r--src/wallet/init.cpp10
-rw-r--r--src/wallet/init.h6
2 files changed, 12 insertions, 4 deletions
diff --git a/src/wallet/init.cpp b/src/wallet/init.cpp
index f58f3bc545..2b5c6b1737 100644
--- a/src/wallet/init.cpp
+++ b/src/wallet/init.cpp
@@ -246,8 +246,14 @@ bool OpenWallets()
return true;
}
-void FlushWallets(bool shutdown) {
+void FlushWallets() {
for (CWalletRef pwallet : vpwallets) {
- pwallet->Flush(shutdown);
+ pwallet->Flush(false);
+ }
+}
+
+void StopWallets() {
+ for (CWalletRef pwallet : vpwallets) {
+ pwallet->Flush(true);
}
}
diff --git a/src/wallet/init.h b/src/wallet/init.h
index 5445c72d1c..c06b058474 100644
--- a/src/wallet/init.h
+++ b/src/wallet/init.h
@@ -23,6 +23,8 @@ bool VerifyWallets();
bool OpenWallets();
//! Flush all wallets in preparation for shutdown.
-//! Call with shutdown = true to actually shutdown the wallet.
-void FlushWallets(bool shutdown);
+void FlushWallets();
+
+//! Stop all wallets. Wallets will be flushed first.
+void StopWallets();
#endif // BITCOIN_WALLET_INIT_H