mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-14 12:43:40 +02:00
Merge 4d0c00dffd into merged_master (Bitcoin PR bitcoin/bitcoin#25168)
This commit is contained in:
commit
66bc45020f
21 changed files with 68 additions and 94 deletions
8
src/node/interfaces.cpp
Normal file → Executable file
8
src/node/interfaces.cpp
Normal file → Executable file
|
|
@ -228,7 +228,7 @@ public:
|
|||
uint256 getBestBlockHash() override
|
||||
{
|
||||
const CBlockIndex* tip = WITH_LOCK(::cs_main, return chainman().ActiveChain().Tip());
|
||||
return tip ? tip->GetBlockHash() : Params().GenesisBlock().GetHash();
|
||||
return tip ? tip->GetBlockHash() : chainman().GetParams().GenesisBlock().GetHash();
|
||||
}
|
||||
int64_t getLastBlockTime() override
|
||||
{
|
||||
|
|
@ -236,7 +236,7 @@ public:
|
|||
if (chainman().ActiveChain().Tip()) {
|
||||
return chainman().ActiveChain().Tip()->GetBlockTime();
|
||||
}
|
||||
return Params().GenesisBlock().GetBlockTime(); // Genesis block's time of current network
|
||||
return chainman().GetParams().GenesisBlock().GetBlockTime(); // Genesis block's time of current network
|
||||
}
|
||||
double getVerificationProgress() override
|
||||
{
|
||||
|
|
@ -245,7 +245,7 @@ public:
|
|||
LOCK(::cs_main);
|
||||
tip = chainman().ActiveChain().Tip();
|
||||
}
|
||||
return GuessVerificationProgress(tip, Params().GetConsensus().nPowTargetSpacing);
|
||||
return GuessVerificationProgress(tip, chainman().GetParams().GetConsensus().nPowTargetSpacing);
|
||||
}
|
||||
bool isInitialBlockDownload() override {
|
||||
return chainman().ActiveChainstate().IsInitialBlockDownload();
|
||||
|
|
@ -546,7 +546,7 @@ public:
|
|||
double guessVerificationProgress(const uint256& block_hash) override
|
||||
{
|
||||
LOCK(cs_main);
|
||||
return GuessVerificationProgress(chainman().m_blockman.LookupBlockIndex(block_hash), Params().GetConsensus().nPowTargetSpacing);
|
||||
return GuessVerificationProgress(chainman().m_blockman.LookupBlockIndex(block_hash), chainman().GetParams().GetConsensus().nPowTargetSpacing);
|
||||
}
|
||||
bool hasBlocks(const uint256& block_hash, int min_height, std::optional<int> max_height) override
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue