aboutsummaryrefslogtreecommitdiffstats
path: root/core/state_transition.go
diff options
context:
space:
mode:
Diffstat (limited to 'core/state_transition.go')
-rw-r--r--core/state_transition.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/core/state_transition.go b/core/state_transition.go
index 3c45ddbf9..820ba66e6 100644
--- a/core/state_transition.go
+++ b/core/state_transition.go
@@ -141,9 +141,8 @@ func (self *StateTransition) TransitionState() (err error) {
}
var (
- tx = self.tx
- sender = self.Sender()
- receiver *state.StateObject
+ tx = self.tx
+ sender = self.Sender()
)
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)