Page MenuHomePhabricator

validation: Remove global ::ActivateBestChain
ClosedPublic

Authored by PiRK on Mar 16 2022, 09:22.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC4c1753474985: validation: Remove global ::ActivateBestChain
Summary

Instead use CChainState::ActivateBestChain, which is what the global one calls anyway.

This is a backport of core#20749 [12/17]
https://github.com/bitcoin/bitcoin/pull/20749/commits/5f8cd7b3a527999512161956db4d718688cb956f

Depends on D11183

Note that the change in default argument from a null CBlock shared pointer to a nullptr does not change behavior, as both cases lead to the same code path of ActivateBestChainStep() being called with a null Cblock pointer.

Test Plan

ninja all check-all