Fix IsInitialBlockDownload to play nice with testnet
This commit is contained in:
parent
2f3f4af4cc
commit
8aa722609d
1 changed files with 1 additions and 1 deletions
|
@ -1384,7 +1384,7 @@ bool IsInitialBlockDownload()
|
|||
if (lockIBDState)
|
||||
return false;
|
||||
bool state = (chainActive.Height() < pindexBestHeader->nHeight - 24 * 6 ||
|
||||
pindexBestHeader->GetBlockTime() < GetTime() - nMaxTipAge);
|
||||
std::max(chainActive.Tip()->GetBlockTime(), pindexBestHeader->GetBlockTime()) < GetTime() - nMaxTipAge);
|
||||
if (!state)
|
||||
lockIBDState = true;
|
||||
return state;
|
||||
|
|
Loading…
Reference in a new issue