aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--eth/gasprice.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/eth/gasprice.go b/eth/gasprice.go
index 6f46559a2..12e76fc2c 100644
--- a/eth/gasprice.go
+++ b/eth/gasprice.go
@@ -162,6 +162,9 @@ func (self *GasPriceOracle) SuggestPrice() *big.Int {
if base == nil {
base = self.eth.GpoMinGasPrice
}
+ if base == nil {
+ return big.NewInt(10000000000000) // apparently MinGasPrice is not initialized during some tests
+ }
baseCorr := new(big.Int).Mul(base, big.NewInt(int64(100+self.eth.GpobaseCorrectionFactor)))
baseCorr.Div(baseCorr, big.NewInt(100))