Skip to content
This repository was archived by the owner on Oct 28, 2021. It is now read-only.

Commit b088c10

Browse files
committed
Fix returning out of gas
1 parent 97e8e7c commit b088c10

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libaleth-precompiles/PrecompilesVM.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ evmc_result execute(evmc_vm*, const evmc_host_interface*, evmc_host_context*,
272272
auto const gasCost = precompile.first(input, _rev);
273273
auto const gasLeft = _msg->gas - gasCost;
274274
if (gasLeft < 0)
275-
return evmc::make_result(EVMC_SUCCESS, 0, nullptr, 0);
275+
return evmc::make_result(EVMC_OUT_OF_GAS, 0, nullptr, 0);
276276

277277
// Execute.
278278
auto const res = precompile.second(input);

0 commit comments

Comments
 (0)