diff --git a/libethereum/State.cpp b/libethereum/State.cpp index d468d33ec..5eb315439 100644 --- a/libethereum/State.cpp +++ b/libethereum/State.cpp @@ -1195,7 +1195,10 @@ bool State::call(Address _receiveAddress, Address _codeAddress, Address _senderA if (it != c_precompiled.end()) { if (*_gas < it->second.gas) + { + *_gas = 0; return false; + } *_gas -= it->second.gas; it->second.exec(_data, _out);