forked from cerc-io/plugeth
null ptr fix
This commit is contained in:
parent
3043b233ea
commit
008e91db6a
@ -143,7 +143,6 @@ func (self *StateTransition) TransitionState() (err error) {
|
||||
var (
|
||||
tx = self.tx
|
||||
sender = self.Sender()
|
||||
receiver *state.StateObject
|
||||
)
|
||||
|
||||
defer self.RefundGas()
|
||||
@ -175,7 +174,7 @@ func (self *StateTransition) TransitionState() (err error) {
|
||||
if tx.CreatesContract() {
|
||||
self.rec = MakeContract(tx, self.state)
|
||||
|
||||
ret, err, ref = vmenv.Create(sender, receiver.Address(), self.tx.Data, self.gas, self.gasPrice, self.value)
|
||||
ret, err, ref = vmenv.Create(sender, self.rec.Address(), self.tx.Data, self.gas, self.gasPrice, self.value)
|
||||
ref.SetCode(ret)
|
||||
} else {
|
||||
ret, err = vmenv.Call(self.Sender(), self.Receiver().Address(), self.tx.Data, self.gas, self.gasPrice, self.value)
|
||||
|
Loading…
Reference in New Issue
Block a user