mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-16 13:01:19 +02:00
validation: Farewell, global Chainstate!
This commit is contained in:
parent
972c5166ee
commit
6f994882de
7 changed files with 8 additions and 35 deletions
|
|
@ -101,21 +101,6 @@ bool CBlockIndexWorkComparator::operator()(const CBlockIndex *pa, const CBlockIn
|
|||
return false;
|
||||
}
|
||||
|
||||
ChainstateManager g_chainman;
|
||||
|
||||
CChainState& ChainstateActive()
|
||||
{
|
||||
LOCK(::cs_main);
|
||||
assert(g_chainman.m_active_chainstate);
|
||||
return *g_chainman.m_active_chainstate;
|
||||
}
|
||||
|
||||
CChain& ChainActive()
|
||||
{
|
||||
LOCK(::cs_main);
|
||||
return ::ChainstateActive().m_chain;
|
||||
}
|
||||
|
||||
/**
|
||||
* Mutex to guard access to validation specific variables, such as reading
|
||||
* or changing the chainstate.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue