diff options
author | obscuren <geffobscura@gmail.com> | 2015-05-15 06:43:00 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-05-15 06:43:10 +0800 |
commit | b71091e337fef7e3cfad56c61c97a42094e87531 (patch) | |
tree | e3945e86e63714aeb77569cca28329a73de608d7 /eth/backend.go | |
parent | 0f76a1c6df44bc3242a64e76bef66dfe312d259b (diff) | |
download | go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.tar go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.tar.gz go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.tar.bz2 go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.tar.lz go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.tar.xz go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.tar.zst go-tangerine-b71091e337fef7e3cfad56c61c97a42094e87531.zip |
eth, eth/downloader, miner: use download events to check miner start
Diffstat (limited to 'eth/backend.go')
-rw-r--r-- | eth/backend.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/eth/backend.go b/eth/backend.go index 362a7eab7..064018955 100644 --- a/eth/backend.go +++ b/eth/backend.go @@ -265,12 +265,12 @@ func New(config *Config) (*Ethereum, error) { } eth.chainManager = core.NewChainManager(blockDb, stateDb, eth.EventMux()) - eth.downloader = downloader.New(eth.chainManager.HasBlock, eth.chainManager.GetBlock) + eth.downloader = downloader.New(eth.EventMux(), eth.chainManager.HasBlock, eth.chainManager.GetBlock) eth.pow = ethash.New() eth.txPool = core.NewTxPool(eth.EventMux(), eth.chainManager.State, eth.chainManager.GasLimit) eth.blockProcessor = core.NewBlockProcessor(stateDb, extraDb, eth.pow, eth.txPool, eth.chainManager, eth.EventMux()) eth.chainManager.SetProcessor(eth.blockProcessor) - eth.miner = miner.New(eth, eth.pow) + eth.miner = miner.New(eth, eth.EventMux(), eth.pow) eth.miner.SetGasPrice(config.GasPrice) eth.protocolManager = NewProtocolManager(config.ProtocolVersion, config.NetworkId, eth.eventMux, eth.txPool, eth.chainManager, eth.downloader) |