Test
This commit is contained in:
12
src/main.cpp
12
src/main.cpp
@@ -4395,7 +4395,7 @@ bool static LoadBlockIndexDB()
|
||||
const CChainParams& chainparams = Params();
|
||||
if (!pblocktree->LoadBlockIndexGuts())
|
||||
return false;
|
||||
|
||||
fprintf(stderr,"load blockindexDB %u\n",(uint32_t)time(NULL));
|
||||
boost::this_thread::interruption_point();
|
||||
|
||||
// Calculate nChainWork
|
||||
@@ -4407,7 +4407,9 @@ bool static LoadBlockIndexDB()
|
||||
vSortedByHeight.push_back(make_pair(pindex->nHeight, pindex));
|
||||
//komodo_pindex_init(pindex,(int32_t)pindex->nHeight);
|
||||
}
|
||||
fprintf(stderr,"load blockindexDB paired %u\n",(uint32_t)time(NULL));
|
||||
sort(vSortedByHeight.begin(), vSortedByHeight.end());
|
||||
fprintf(stderr,"load blockindexDB sorted %u\n",(uint32_t)time(NULL));
|
||||
BOOST_FOREACH(const PAIRTYPE(int, CBlockIndex*)& item, vSortedByHeight)
|
||||
{
|
||||
CBlockIndex* pindex = item.second;
|
||||
@@ -4456,7 +4458,8 @@ bool static LoadBlockIndexDB()
|
||||
pindexBestHeader = pindex;
|
||||
//komodo_pindex_init(pindex,(int32_t)pindex->nHeight);
|
||||
}
|
||||
|
||||
fprintf(stderr,"load blockindexDB chained %u\n",(uint32_t)time(NULL));
|
||||
|
||||
// Load block file info
|
||||
pblocktree->ReadLastBlockFile(nLastBlockFile);
|
||||
vinfoBlockFile.resize(nLastBlockFile + 1);
|
||||
@@ -4485,6 +4488,7 @@ bool static LoadBlockIndexDB()
|
||||
}
|
||||
//komodo_pindex_init(pindex,(int32_t)pindex->nHeight);
|
||||
}
|
||||
fprintf(stderr,"load blockindexDB %u\n",(uint32_t)time(NULL));
|
||||
for (std::set<int>::iterator it = setBlkDataFiles.begin(); it != setBlkDataFiles.end(); it++)
|
||||
{
|
||||
CDiskBlockPos pos(*it, 0);
|
||||
@@ -4583,7 +4587,7 @@ bool CVerifyDB::VerifyDB(CCoinsView *coinsview, int nCheckLevel, int nCheckDepth
|
||||
CValidationState state;
|
||||
// No need to verify JoinSplits twice
|
||||
auto verifier = libzcash::ProofVerifier::Disabled();
|
||||
fprintf(stderr,"start VerifyDB %u\n",(uint32_t)time(NULL));
|
||||
//fprintf(stderr,"start VerifyDB %u\n",(uint32_t)time(NULL));
|
||||
for (CBlockIndex* pindex = chainActive.Tip(); pindex && pindex->pprev; pindex = pindex->pprev)
|
||||
{
|
||||
boost::this_thread::interruption_point();
|
||||
@@ -4621,7 +4625,7 @@ bool CVerifyDB::VerifyDB(CCoinsView *coinsview, int nCheckLevel, int nCheckDepth
|
||||
if (ShutdownRequested())
|
||||
return true;
|
||||
}
|
||||
fprintf(stderr,"end VerifyDB %u\n",(uint32_t)time(NULL));
|
||||
//fprintf(stderr,"end VerifyDB %u\n",(uint32_t)time(NULL));
|
||||
if (pindexFailure)
|
||||
return error("VerifyDB(): *** coin database inconsistencies found (last %i blocks, %i good transactions before that)\n", chainActive.Height() - pindexFailure->nHeight + 1, nGoodTransactions);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user