Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

Commit

Permalink
Update x/evm/keeper/state_transition.go
Browse files Browse the repository at this point in the history
  • Loading branch information
fedekunze authored Jul 18, 2022
1 parent 34aad8e commit 7a044e8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion x/evm/keeper/state_transition.go
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ func (k *Keeper) ApplyMessageWithConfig(ctx sdk.Context, msg core.Message, trace
minimumGasUsed := gasLimit.Mul(minGasMultiplier)

if msg.Gas() < leftoverGas {
return nil, sdkerrors.Wrap(types.ErrGasOverflow, "apply message")
return nil, sdkerrors.Wrapf(types.ErrGasOverflow, "message gas limit < leftover gas (%d < %d)", msg.Gas(), leftoverGas)
}
temporaryGasUsed := msg.Gas() - leftoverGas
gasUsed := sdk.MaxDec(minimumGasUsed, sdk.NewDec(int64(temporaryGasUsed))).TruncateInt().Uint64()
Expand Down

0 comments on commit 7a044e8

Please sign in to comment.