Skip to content

Commit

Permalink
clear StakeableCoins before initializing
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterL73 committed Dec 27, 2020
1 parent 9d95c16 commit f12af33
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/wallet/wallet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2414,6 +2414,8 @@ bool CWallet::StakeableCoins(std::vector<CStakeableOutput>* pCoins)
const bool fIncludeColdStaking = !sporkManager.IsSporkActive(SPORK_19_COLDSTAKING_MAINTENANCE) &&
gArgs.GetBoolArg("-coldstaking", DEFAULT_COLDSTAKING);

if (pCoins) pCoins->clear();

LOCK2(cs_main, cs_wallet);
for (const auto& it : mapWallet) {
const uint256& wtxid = it.first;
Expand Down

0 comments on commit f12af33

Please sign in to comment.