Do not pass Consensus::Params& to Chainstate helpers

This commit is contained in:
MacroFake
2022-05-18 18:49:36 +02:00
parent fa4ee53dca
commit faf012b438
5 changed files with 3 additions and 13 deletions

View File

@@ -1438,7 +1438,6 @@ bool AppInitMain(NodeContext& node, interfaces::BlockAndHeaderTipInfo* tip_info)
chainman,
Assert(node.mempool.get()),
fPruneMode,
chainparams.GetConsensus(),
fReindexChainState,
cache_sizes.block_tree_db,
cache_sizes.coins_db,
@@ -1485,7 +1484,7 @@ bool AppInitMain(NodeContext& node, interfaces::BlockAndHeaderTipInfo* tip_info)
break;
case ChainstateLoadingError::ERROR_BLOCKS_WITNESS_INSUFFICIENTLY_VALIDATED:
strLoadError = strprintf(_("Witness data for blocks after height %d requires validation. Please restart with -reindex."),
chainparams.GetConsensus().SegwitHeight);
chainman.GetConsensus().SegwitHeight);
break;
case ChainstateLoadingError::SHUTDOWN_PROBED:
break;
@@ -1502,7 +1501,6 @@ bool AppInitMain(NodeContext& node, interfaces::BlockAndHeaderTipInfo* tip_info)
maybe_verify_error = VerifyLoadedChainstate(chainman,
fReset,
fReindexChainState,
chainparams.GetConsensus(),
check_blocks,
args.GetIntArg("-checklevel", DEFAULT_CHECKLEVEL));
} catch (const std::exception& e) {