mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-16 13:01:19 +02:00
Add BlockManagerOpts::chainparams reference
and use it in blockstorage.cpp
This commit is contained in:
parent
6c7ebcc14b
commit
facdb8b331
8 changed files with 31 additions and 9 deletions
|
|
@ -381,10 +381,13 @@ struct SnapshotTestSetup : TestChain100Setup {
|
|||
.datadir = m_args.GetDataDirNet(),
|
||||
.adjusted_time_callback = GetAdjustedTime,
|
||||
};
|
||||
node::BlockManager::Options blockman_opts{
|
||||
.chainparams = chainman_opts.chainparams,
|
||||
};
|
||||
// For robustness, ensure the old manager is destroyed before creating a
|
||||
// new one.
|
||||
m_node.chainman.reset();
|
||||
m_node.chainman = std::make_unique<ChainstateManager>(chainman_opts, node::BlockManager::Options{});
|
||||
m_node.chainman = std::make_unique<ChainstateManager>(chainman_opts, blockman_opts);
|
||||
}
|
||||
return *Assert(m_node.chainman);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue