wallet: Add AddWallet, RemoveWallet, GetWallet and GetWallets

With these new functions all vpwallets usage are removed
and vpwallets is now a static variable (no external linkage).
This commit is contained in:
João Barbosa
2018-04-17 18:22:23 +01:00
parent 6efd9644cf
commit 373aee26c3
9 changed files with 72 additions and 38 deletions

View File

@@ -756,7 +756,7 @@ void MaybeCompactWalletDB()
return;
}
for (CWallet* pwallet : vpwallets) {
for (CWallet* pwallet : GetWallets()) {
WalletDatabase& dbh = pwallet->GetDBHandle();
unsigned int nUpdateCounter = dbh.nUpdateCounter;