log: Avoid treating remote misbehvior as local system error

This commit is contained in:
MarcoFalke 2020-07-15 10:39:38 +02:00
parent fa492895b5
commit fa56eda58e
No known key found for this signature in database
GPG key ID: CE2B75697E69A548

View file

@ -3641,8 +3641,10 @@ bool BlockManager::AcceptBlockHeader(const CBlockHeader& block, BlockValidationS
return true;
}
if (!CheckBlockHeader(block, state, chainparams.GetConsensus()))
return error("%s: Consensus::CheckBlockHeader: %s, %s", __func__, hash.ToString(), state.ToString());
if (!CheckBlockHeader(block, state, chainparams.GetConsensus())) {
LogPrint(BCLog::VALIDATION, "%s: Consensus::CheckBlockHeader: %s, %s\n", __func__, hash.ToString(), state.ToString());
return false;
}
// Get prev block index
CBlockIndex* pindexPrev = nullptr;