Skip to content

Commit

Permalink
core: fix preCheck for RandomizeSMC after EIP-1559
Browse files Browse the repository at this point in the history
  • Loading branch information
gzliudan committed Nov 19, 2024
1 parent 370c6b6 commit 4855f19
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/state_transition.go
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ func (st *StateTransition) preCheck() error {
}
// This will panic if baseFee is nil, but basefee presence is verified
// as part of header validation.
if st.gasFeeCap.Cmp(st.evm.Context.BaseFee) < 0 {
if (msg.To() == nil || *msg.To() != common.RandomizeSMCBinary) && st.gasFeeCap.Cmp(st.evm.Context.BaseFee) < 0 {
return fmt.Errorf("%w: address %v, maxFeePerGas: %s baseFee: %s", ErrFeeCapTooLow,
msg.From().Hex(), st.gasFeeCap, st.evm.Context.BaseFee)
}
Expand Down

0 comments on commit 4855f19

Please sign in to comment.