mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-05-13 03:30:42 +02:00
refactoring: introduce unused ChainActive()
in preparation for the following scripted-diff commit.
This commit is contained in:
parent
1b6e6fcfd2
commit
a3a609079c
@ -220,6 +220,8 @@ private:
|
||||
void EraseBlockData(CBlockIndex* index) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
} g_chainstate;
|
||||
|
||||
CChain& ChainActive() { return g_chainstate.m_chain; }
|
||||
|
||||
/**
|
||||
* Mutex to guard access to validation specific variables, such as reading
|
||||
* or changing the chainstate.
|
||||
|
@ -438,6 +438,9 @@ void ResetBlockFailureFlags(CBlockIndex* pindex) EXCLUSIVE_LOCKS_REQUIRED(cs_mai
|
||||
/** The currently-connected chain of blocks (protected by cs_main). */
|
||||
extern CChain& chainActive;
|
||||
|
||||
/** @returns the most-work chain. */
|
||||
CChain& ChainActive();
|
||||
|
||||
/** Global variable that points to the coins database (protected by cs_main) */
|
||||
extern std::unique_ptr<CCoinsViewDB> pcoinsdbview;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user