aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2014-04-09 22:00:28 +0800
committerobscuren <geffobscura@gmail.com>2014-04-09 22:00:28 +0800
commit6d28bf534f0fabb5740ef035b829e5edc4dc3131 (patch)
tree081fda1e25a5928b5313b4d8c8acf67af20da9f9
parentc0cad0b534f8e0bdd20f57480883d92ea0ffe9f0 (diff)
downloaddexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.tar
dexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.tar.gz
dexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.tar.bz2
dexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.tar.lz
dexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.tar.xz
dexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.tar.zst
dexon-6d28bf534f0fabb5740ef035b829e5edc4dc3131.zip
Added a length for copy
-rw-r--r--ethchain/state_manager.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/ethchain/state_manager.go b/ethchain/state_manager.go
index c33ba9272..4c001a387 100644
--- a/ethchain/state_manager.go
+++ b/ethchain/state_manager.go
@@ -288,7 +288,7 @@ func (sm *StateManager) AccumelateRewards(block *Block) error {
// Reward amount of ether to the coinbase address
addr.AddFee(CalculateBlockReward(block, len(block.Uncles)))
- var acc []byte
+ acc := make([]byte, len(block.Coinbase))
copy(acc, block.Coinbase)
sm.procState.UpdateAccount(acc, addr)