diff options
author | Jeffrey Wilcke <jeffrey@ethereum.org> | 2015-06-16 00:09:44 +0800 |
---|---|---|
committer | Jeffrey Wilcke <jeffrey@ethereum.org> | 2015-06-16 00:09:44 +0800 |
commit | cc0b451119478ba4a005ec8840573252636f45dc (patch) | |
tree | f1e9882b7dea20eab9cd30850224a07bb312f067 /rpc/api/eth.go | |
parent | f2a2164184a9397d8e6100c370595ccdcd00ca0b (diff) | |
parent | 2628103f1df35ad6a130f2f41e73c7703bf61886 (diff) | |
download | go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.tar go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.tar.gz go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.tar.bz2 go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.tar.lz go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.tar.xz go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.tar.zst go-tangerine-cc0b451119478ba4a005ec8840573252636f45dc.zip |
Merge pull request #1260 from obscuren/tx-drop-low-tx
core: drop low gas tx
Diffstat (limited to 'rpc/api/eth.go')
-rw-r--r-- | rpc/api/eth.go | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/rpc/api/eth.go b/rpc/api/eth.go index 943f19b90..66ee69930 100644 --- a/rpc/api/eth.go +++ b/rpc/api/eth.go @@ -259,7 +259,14 @@ func (self *ethApi) SendTransaction(req *shared.Request) (interface{}, error) { nonce = args.Nonce.String() } - v, err := self.xeth.Transact(args.From, args.To, nonce, args.Value.String(), args.Gas.String(), args.GasPrice.String(), args.Data) + var gas, price string + if args.Gas != nil { + gas = args.Gas.String() + } + if args.GasPrice != nil { + price = args.GasPrice.String() + } + v, err := self.xeth.Transact(args.From, args.To, nonce, args.Value.String(), gas, price, args.Data) if err != nil { return nil, err } |