Merge branch 'hotfix/0.6.5-1' into develop

poc8
obscuren 10 years ago
commit 1b66e1c93a
  1. 8
      ethminer/miner.go

@ -3,6 +3,7 @@ package ethminer
import (
"bytes"
"sort"
"time"
"github.com/ethereum/eth-go/ethchain"
"github.com/ethereum/eth-go/ethlog"
@ -135,6 +136,12 @@ func (miner *Miner) listener() {
}
}
default:
// This hack is only temporarily
if len(miner.txs) == 0 {
time.Sleep(2 * time.Second)
continue
}
miner.mineNewBlock()
}
}
@ -159,6 +166,7 @@ func (miner *Miner) Stop() {
}
func (self *Miner) mineNewBlock() {
stateManager := self.ethereum.StateManager()
self.block = self.ethereum.BlockChain().NewBlock(self.coinbase)

Loading…
Cancel
Save