diff options
author | Russell Yanofsky <russ@yanofsky.org> | 2020-05-28 13:06:43 -0400 |
---|---|---|
committer | Russell Yanofsky <russ@yanofsky.org> | 2021-08-17 04:05:15 -0400 |
commit | 62a09a30772141ef4add2f10d29927211abf57eb (patch) | |
tree | 7158ee4508efa9696316741cafcddad9a507b7cd /src/wallet/walletdb.cpp | |
parent | fdd80b0a53b4af0b29cb6e03118e2456d053a757 (diff) | |
download | bitcoin-62a09a30772141ef4add2f10d29927211abf57eb.tar.xz |
refactor: remove ::vpwallets and related global variables
Move global wallet variables to WalletContext struct
Diffstat (limited to 'src/wallet/walletdb.cpp')
-rw-r--r-- | src/wallet/walletdb.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/wallet/walletdb.cpp b/src/wallet/walletdb.cpp index 1e5d8dfa3a..2fabe65a93 100644 --- a/src/wallet/walletdb.cpp +++ b/src/wallet/walletdb.cpp @@ -1004,14 +1004,14 @@ DBErrors WalletBatch::ZapSelectTx(std::vector<uint256>& vTxHashIn, std::vector<u return DBErrors::LOAD_OK; } -void MaybeCompactWalletDB() +void MaybeCompactWalletDB(WalletContext& context) { static std::atomic<bool> fOneThread(false); if (fOneThread.exchange(true)) { return; } - for (const std::shared_ptr<CWallet>& pwallet : GetWallets()) { + for (const std::shared_ptr<CWallet>& pwallet : GetWallets(context)) { WalletDatabase& dbh = pwallet->GetDatabase(); unsigned int nUpdateCounter = dbh.nUpdateCounter; |