Only log nbits in ContextualCheckBlockHeader if -debug
This commit is contained in:
@@ -5114,7 +5114,9 @@ bool ContextualCheckBlockHeader(const CBlockHeader& block, CValidationState& sta
|
|||||||
// changing at run-time, from Consensus::Params being a const struct
|
// changing at run-time, from Consensus::Params being a const struct
|
||||||
unsigned int nNextWork = GetNextWorkRequired(pindexPrev, &block, consensusParams);
|
unsigned int nNextWork = GetNextWorkRequired(pindexPrev, &block, consensusParams);
|
||||||
|
|
||||||
LogPrintf("%s: nbits ,%d,%lu,%lu,%d\n",__func__, nHeight, nNextWork, block.nBits, nNextWork - block.nBits );
|
if (fDebug) {
|
||||||
|
LogPrintf("%s: nbits ,%d,%lu,%lu,%d\n",__func__, nHeight, nNextWork, block.nBits, nNextWork - block.nBits );
|
||||||
|
}
|
||||||
if (block.nBits != nNextWork) {
|
if (block.nBits != nNextWork) {
|
||||||
// Enforce correct nbits at DAA fork height, before that, ignore
|
// Enforce correct nbits at DAA fork height, before that, ignore
|
||||||
if (nHeight > daaForkHeight) {
|
if (nHeight > daaForkHeight) {
|
||||||
|
|||||||
Reference in New Issue
Block a user