diff options
author | Nick Johnson <arachnid@notdot.net> | 2017-06-27 23:15:29 +0800 |
---|---|---|
committer | Nick Johnson <arachnid@notdot.net> | 2017-06-28 22:58:41 +0800 |
commit | 055095798911e3c6f2e210220cb7ece1b71f6517 (patch) | |
tree | 27f22dcec90015971a464b15ca8d73736756906d /eth/handler.go | |
parent | dfd076244dd0c2d809f9dd0080feab167ba9560c (diff) | |
download | dexon-055095798911e3c6f2e210220cb7ece1b71f6517.tar.gz dexon-055095798911e3c6f2e210220cb7ece1b71f6517.tar.zst dexon-055095798911e3c6f2e210220cb7ece1b71f6517.zip |
eth, les, light: Refactor downloader to use blockchain interface
Diffstat (limited to 'eth/handler.go')
-rw-r--r-- | eth/handler.go | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/eth/handler.go b/eth/handler.go index 1af9e755b..8d026c775 100644 --- a/eth/handler.go +++ b/eth/handler.go @@ -157,10 +157,7 @@ func NewProtocolManager(config *params.ChainConfig, mode downloader.SyncMode, ne return nil, errIncompatibleConfig } // Construct the different synchronisation mechanisms - manager.downloader = downloader.New(mode, chaindb, manager.eventMux, blockchain.HasHeader, blockchain.HasBlockAndState, blockchain.GetHeaderByHash, - blockchain.GetBlockByHash, blockchain.CurrentHeader, blockchain.CurrentBlock, blockchain.CurrentFastBlock, blockchain.FastSyncCommitHead, - blockchain.GetTdByHash, blockchain.InsertHeaderChain, manager.blockchain.InsertChain, blockchain.InsertReceiptChain, blockchain.Rollback, - manager.removePeer) + manager.downloader = downloader.New(mode, chaindb, manager.eventMux, blockchain, nil, manager.removePeer) validator := func(header *types.Header) error { return engine.VerifyHeader(blockchain, header, true) |