aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2020-06-02 13:45:19 -0400
committerMarcoFalke <falke.marco@gmail.com>2020-06-03 06:06:58 -0400
commitfa3b4f9b8e54ec07aeb2e5e2333da3e784f7be12 (patch)
treefac8c59b273e83bdf43714b56510b8e1d1acc1c3 /src
parentfa1d5800d9c5e33942b76f6667839a818723dee9 (diff)
validation: Make VerifyDB level 4 interruptible
Diffstat (limited to 'src')
-rw-r--r--src/validation.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/validation.cpp b/src/validation.cpp
index dc3fe1cdf0..1ce440dc04 100644
--- a/src/validation.cpp
+++ b/src/validation.cpp
@@ -4313,8 +4313,7 @@ bool CVerifyDB::VerifyDB(const CChainParams& chainparams, CCoinsView *coinsview,
nGoodTransactions += block.vtx.size();
}
}
- if (ShutdownRequested())
- return true;
+ if (ShutdownRequested()) return true;
}
if (pindexFailure)
return error("VerifyDB(): *** coin database inconsistencies found (last %i blocks, %i good transactions before that)\n", ::ChainActive().Height() - pindexFailure->nHeight + 1, nGoodTransactions);
@@ -4338,6 +4337,7 @@ bool CVerifyDB::VerifyDB(const CChainParams& chainparams, CCoinsView *coinsview,
return error("VerifyDB(): *** ReadBlockFromDisk failed at %d, hash=%s", pindex->nHeight, pindex->GetBlockHash().ToString());
if (!::ChainstateActive().ConnectBlock(block, state, pindex, coins, chainparams))
return error("VerifyDB(): *** found unconnectable block at %d, hash=%s (%s)", pindex->nHeight, pindex->GetBlockHash().ToString(), state.ToString());
+ if (ShutdownRequested()) return true;
}
}