Merge pull request #11 from guagualvcha/gas_limit

[R4R]remove redundant gaslimit check
This commit is contained in:
zjubfd 2020-06-24 16:22:21 +08:00 committed by GitHub
commit 11bc803884
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -336,10 +336,6 @@ func (p *Parlia) verifyHeader(chain consensus.ChainReader, header *types.Header,
if len(header.Extra) < extraVanity+extraSeal {
return errMissingSignature
}
// Verify that the gasUsed is <= gasLimit
if header.GasUsed > header.GasLimit {
return fmt.Errorf("invalid gasUsed: have %d, gasLimit %d", header.GasUsed, header.GasLimit)
}
// check extra data
isEpoch := number%p.config.Epoch == 0