diff options
author | Jason Carver <ut96caarrs@snkmail.com> | 2015-05-27 09:55:52 +0800 |
---|---|---|
committer | Jason Carver <ut96caarrs@snkmail.com> | 2015-05-27 09:55:52 +0800 |
commit | de12183d3824c25763e8996c14f8b5a52832fad6 (patch) | |
tree | c5b4698b91eefa50389737159f2ad9be0a4d983b /miner | |
parent | 6019f1bb0a0744ffa52bf1ab93309c1a6dd9063c (diff) | |
download | dexon-de12183d3824c25763e8996c14f8b5a52832fad6.tar.gz dexon-de12183d3824c25763e8996c14f8b5a52832fad6.tar.zst dexon-de12183d3824c25763e8996c14f8b5a52832fad6.zip |
deep-mining-log: need ring buffer to be one bigger for all-blocks-mined case
Diffstat (limited to 'miner')
-rw-r--r-- | miner/worker.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/miner/worker.go b/miner/worker.go index fac2e6568..12ed65626 100644 --- a/miner/worker.go +++ b/miner/worker.go @@ -219,7 +219,7 @@ out: func newLocalMinedBlock(blockNumber uint64, prevMinedBlocks *uint64RingBuffer) (minedBlocks *uint64RingBuffer) { if prevMinedBlocks == nil { - minedBlocks = &uint64RingBuffer{next: 0, ints: make([]uint64, miningLogAtDepth)} + minedBlocks = &uint64RingBuffer{next: 0, ints: make([]uint64, miningLogAtDepth + 1)} } else { minedBlocks = prevMinedBlocks } |