aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeffrey Wilcke <jeffrey@ethereum.org>2015-05-27 08:04:42 +0800
committerJeffrey Wilcke <jeffrey@ethereum.org>2015-05-27 08:04:42 +0800
commitaada35af9b6c7acd78a427a43f02bcd702697d59 (patch)
treee51380fdbb4be105d7fdd2783122511f1150bb8f
parent3590591e674b14fd025aac91952d9408bb841527 (diff)
parentbe2b0501b5832c0b49f07cdf2db597cc34450199 (diff)
downloaddexon-aada35af9b6c7acd78a427a43f02bcd702697d59.tar
dexon-aada35af9b6c7acd78a427a43f02bcd702697d59.tar.gz
dexon-aada35af9b6c7acd78a427a43f02bcd702697d59.tar.bz2
dexon-aada35af9b6c7acd78a427a43f02bcd702697d59.tar.lz
dexon-aada35af9b6c7acd78a427a43f02bcd702697d59.tar.xz
dexon-aada35af9b6c7acd78a427a43f02bcd702697d59.tar.zst
dexon-aada35af9b6c7acd78a427a43f02bcd702697d59.zip
Merge pull request #1114 from obscuren/develop
core: block.gasLimit - parent.gasLimit <= parent.gasLimit / GasLimitB…
-rw-r--r--core/block_processor.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/block_processor.go b/core/block_processor.go
index 037782407..e808c03da 100644
--- a/core/block_processor.go
+++ b/core/block_processor.go
@@ -302,7 +302,7 @@ func (sm *BlockProcessor) ValidateHeader(block, parent *types.Header, checkPow b
a := new(big.Int).Sub(block.GasLimit, parent.GasLimit)
a.Abs(a)
b := new(big.Int).Div(parent.GasLimit, params.GasLimitBoundDivisor)
- if !(a.Cmp(b) < 0) || (block.GasLimit.Cmp(params.MinGasLimit) == -1) {
+ if !(a.Cmp(b) <= 0) || (block.GasLimit.Cmp(params.MinGasLimit) == -1) {
return fmt.Errorf("GasLimit check failed for block %v (%v > %v)", block.GasLimit, a, b)
}