Validate NewTx From field is not blank

This commit is contained in:
Taylor Gerring
2015-03-18 20:30:09 -04:00
parent da427e8843
commit 8b20c3cc97
3 changed files with 40 additions and 0 deletions

View File

@ -257,6 +257,11 @@ func (p *EthereumApi) Transact(args *NewTxArgs, reply *interface{}) (err error)
p.register[ags.From] = append(p.register[args.From], args)
}
*/
if err := args.requirements(); err != nil {
return err
}
// TODO: align default values to have the same type, e.g. not depend on
// common.Value conversions later on
if args.Gas.Cmp(big.NewInt(0)) == 0 {