mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-18 02:40:45 +00:00
eth/gasprice: improve stability of estimated price (#22722)
This commit is contained in:
parent
1521b8a663
commit
2b365e8112
1 changed files with 3 additions and 0 deletions
|
|
@ -205,6 +205,9 @@ func (gpo *Oracle) getBlockPrices(ctx context.Context, signer types.Signer, bloc
|
||||||
|
|
||||||
var prices []*big.Int
|
var prices []*big.Int
|
||||||
for _, tx := range txs {
|
for _, tx := range txs {
|
||||||
|
if tx.GasPrice().Cmp(common.Big1) <= 0 {
|
||||||
|
continue
|
||||||
|
}
|
||||||
sender, err := types.Sender(signer, tx)
|
sender, err := types.Sender(signer, tx)
|
||||||
if err == nil && sender != block.Coinbase() {
|
if err == nil && sender != block.Coinbase() {
|
||||||
prices = append(prices, tx.GasPrice())
|
prices = append(prices, tx.GasPrice())
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue