mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-19 23:03:45 +01:00
validation: make CCheckQueueControl's CCheckQueue non-optional
This simplifies the construction logic and will allow the constructor and destructor to lock and unlock uncondiationally.
This commit is contained in:
@@ -2612,7 +2612,7 @@ bool Chainstate::ConnectBlock(const CBlock& block, BlockValidationState& state,
|
||||
// doesn't invalidate pointers into the vector, and keep txsdata in scope
|
||||
// for as long as `control`.
|
||||
std::optional<CCheckQueueControl<CScriptCheck>> control;
|
||||
if (fScriptChecks && parallel_script_checks) control.emplace(&m_chainman.GetCheckQueue());
|
||||
if (fScriptChecks && parallel_script_checks) control.emplace(m_chainman.GetCheckQueue());
|
||||
|
||||
std::vector<PrecomputedTransactionData> txsdata(block.vtx.size());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user