|
|
@ -566,11 +566,11 @@ func (self *XEth) Call(fromStr, toStr, valueStr, gasStr, gasPriceStr, dataStr st |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if msg.gas.Cmp(big.NewInt(0)) == 0 { |
|
|
|
if msg.gas.Cmp(big.NewInt(0)) == 0 { |
|
|
|
msg.gas = self.DefaultGas() |
|
|
|
msg.gas = DefaultGas() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if msg.gasPrice.Cmp(big.NewInt(0)) == 0 { |
|
|
|
if msg.gasPrice.Cmp(big.NewInt(0)) == 0 { |
|
|
|
msg.gasPrice = self.DefaultGasPrice() |
|
|
|
msg.gasPrice = DefaultGasPrice() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
block := self.CurrentBlock() |
|
|
|
block := self.CurrentBlock() |
|
|
@ -616,11 +616,11 @@ func (self *XEth) Transact(fromStr, toStr, valueStr, gasStr, gasPriceStr, codeSt |
|
|
|
// TODO: align default values to have the same type, e.g. not depend on
|
|
|
|
// TODO: align default values to have the same type, e.g. not depend on
|
|
|
|
// common.Value conversions later on
|
|
|
|
// common.Value conversions later on
|
|
|
|
if gas.Cmp(big.NewInt(0)) == 0 { |
|
|
|
if gas.Cmp(big.NewInt(0)) == 0 { |
|
|
|
gas = self.DefaultGas() |
|
|
|
gas = DefaultGas() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if price.Cmp(big.NewInt(0)) == 0 { |
|
|
|
if price.Cmp(big.NewInt(0)) == 0 { |
|
|
|
price = self.DefaultGasPrice() |
|
|
|
price = DefaultGasPrice() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
data = common.FromHex(codeStr) |
|
|
|
data = common.FromHex(codeStr) |
|
|
|