aboutsummaryrefslogtreecommitdiffstats
path: root/miner/worker.go
diff options
context:
space:
mode:
authorJeffrey Wilcke <jeffrey@ethereum.org>2015-06-11 18:32:39 +0800
committerJeffrey Wilcke <jeffrey@ethereum.org>2015-06-11 18:32:39 +0800
commit6609d45ef48ce1c2d2b0e73fa8fe5190d36e3920 (patch)
tree5cb56f1a9ce712178bd19886c389166562f6f328 /miner/worker.go
parent13bd452fafae000b5b3d5769af5554de7c5f9779 (diff)
parent37111aa4bd215cfc8bcfb97cdc7e223649306196 (diff)
downloaddexon-6609d45ef48ce1c2d2b0e73fa8fe5190d36e3920.tar.gz
dexon-6609d45ef48ce1c2d2b0e73fa8fe5190d36e3920.tar.zst
dexon-6609d45ef48ce1c2d2b0e73fa8fe5190d36e3920.zip
Merge pull request #1228 from obscuren/vm-optimisations
core/vm: optimisations
Diffstat (limited to 'miner/worker.go')
-rw-r--r--miner/worker.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/miner/worker.go b/miner/worker.go
index 611445529..bd4bc0e3c 100644
--- a/miner/worker.go
+++ b/miner/worker.go
@@ -270,7 +270,6 @@ func (self *worker) wait() {
func (self *worker) push() {
if atomic.LoadInt32(&self.mining) == 1 {
- self.current.block.Header().GasUsed = self.current.totalUsedGas
self.current.block.SetRoot(self.current.state.Root())
// push new work to agents
@@ -510,6 +509,8 @@ func (self *worker) commitTransactions(transactions types.Transactions) {
current.tcount++
}
}
+
+ self.current.block.Header().GasUsed = self.current.totalUsedGas
}
func (self *worker) commitTransaction(tx *types.Transaction) error {