src/BlockChain/Validators/BlockValidator.cpp
// Validates all the elements in a block that can be checked without additional data. 
// Includes commitment sums and kernels, reward, etc.
Validates all the elements in a block that can be checked without additional data.
Includes commitment sums and kernels, reward, etc.
Validates all the elements in a block that can be checked without additional data . Includes commitment sums and kernels reward etc .
void BlockValidator::VerifySelfConsistent(const FullBlock& block) const
{
	if (block.WasValidated())
	{
		LOG_TRACE_F("Block {} already validated", block);
		return;
	}
	VerifyBody(block);
	VerifyKernelLockHeights(block);
	if (!IsCoinbaseValid(block))
	{
		LOG_ERROR_F("Failed to validate coinbase for {}", block);
		throw BAD_DATA_EXCEPTION("Failed to validate coinbase");
	}
	block.MarkAsValidated();
}
void BlockValidator :: VerifySelfConsistent ( const FullBlock & block ) const { if ( block . WasValidated ( ) ) { LOG_TRACE_F ( " " , block ) ; return ; } VerifyBody ( block ) ; VerifyKernelLockHeights ( block ) ; if ( ! IsCoinbaseValid ( block ) ) { LOG_ERROR_F ( " " , block ) ; throw BAD_DATA_EXCEPTION ( " " ) ; } block . MarkAsValidated ( ) ; }
Validates all the elements in a block that can be checked without additional data.
Validates all the elements in a block that can be checked without additional data .