mirror of
https://github.com/kvazar-network/kevacoin.git
synced 2025-03-09 12:11:16 +00:00
nCheckDepth chain height fix
This commit is contained in:
parent
1d4805ce04
commit
d9d1bd3267
@ -3577,9 +3577,7 @@ bool CVerifyDB::VerifyDB(const CChainParams& chainparams, CCoinsView *coinsview,
|
||||
return true;
|
||||
|
||||
// Verify blocks in the best chain
|
||||
if (nCheckDepth <= 0)
|
||||
nCheckDepth = 1000000000; // suffices until the year 19000
|
||||
if (nCheckDepth > chainActive.Height())
|
||||
if (nCheckDepth <= 0 || nCheckDepth > chainActive.Height())
|
||||
nCheckDepth = chainActive.Height();
|
||||
nCheckLevel = std::max(0, std::min(4, nCheckLevel));
|
||||
LogPrintf("Verifying last %i blocks at level %i\n", nCheckDepth, nCheckLevel);
|
||||
|
Loading…
x
Reference in New Issue
Block a user