Browse Source

fix blockGasLimit bug : 1024 -> 2048

cl-refactor
CJentzsch 10 years ago
committed by Gav Wood
parent
commit
3f8be2aabc
  1. 4
      libethcore/BlockInfo.cpp

4
libethcore/BlockInfo.cpp

@ -206,8 +206,8 @@ void BlockInfo::verifyParent(BlockInfo const& _parent) const
if (difficulty != calculateDifficulty(_parent))
BOOST_THROW_EXCEPTION(InvalidDifficulty());
if (diff(gasLimit, _parent.gasLimit) <= _parent.gasLimit / 1024)
BOOST_THROW_EXCEPTION(InvalidGasLimit(gasLimit, calculateGasLimit(_parent), diff(gasLimit, _parent.gasLimit), _parent.gasLimit / 1024));
if (diff(gasLimit, _parent.gasLimit) <= _parent.gasLimit / 2048)
BOOST_THROW_EXCEPTION(InvalidGasLimit(gasLimit, calculateGasLimit(_parent), diff(gasLimit, _parent.gasLimit), _parent.gasLimit / 2048));
// Check timestamp is after previous timestamp.
if (parentHash)

Loading…
Cancel
Save