mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-15 12:51:00 +02:00
validation: Remove global ::ActivateBestChain
Instead use CChainState::ActivateBestChain, which is what the global one calls anyway.
This commit is contained in:
parent
2a696472a1
commit
5f8cd7b3a5
5 changed files with 9 additions and 18 deletions
|
|
@ -1700,7 +1700,7 @@ void static ProcessGetBlockData(CNode& pfrom, Peer& peer, const CChainParams& ch
|
|||
} // release cs_main before calling ActivateBestChain
|
||||
if (need_activate_chain) {
|
||||
BlockValidationState state;
|
||||
if (!ActivateBestChain(state, chainparams, a_recent_block)) {
|
||||
if (!::ChainstateActive().ActivateBestChain(state, chainparams, a_recent_block)) {
|
||||
LogPrint(BCLog::NET, "failed to activate chain (%s)\n", state.ToString());
|
||||
}
|
||||
}
|
||||
|
|
@ -2960,7 +2960,7 @@ void PeerManagerImpl::ProcessMessage(CNode& pfrom, const std::string& msg_type,
|
|||
a_recent_block = most_recent_block;
|
||||
}
|
||||
BlockValidationState state;
|
||||
if (!ActivateBestChain(state, m_chainparams, a_recent_block)) {
|
||||
if (!::ChainstateActive().ActivateBestChain(state, m_chainparams, a_recent_block)) {
|
||||
LogPrint(BCLog::NET, "failed to activate chain (%s)\n", state.ToString());
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue