aboutsummaryrefslogtreecommitdiffstats
path: root/eth
diff options
context:
space:
mode:
authorobscuren <geffobscura@gmail.com>2015-03-04 00:55:23 +0800
committerobscuren <geffobscura@gmail.com>2015-03-04 00:55:23 +0800
commit313fe3861b3c338b3b6304adac46c86af7e2d52e (patch)
treee19ace3d9fd0b8f8fe67e5f0fb934cfd407b5664 /eth
parent22b132e28f74cabef38a55874da8e3db93786144 (diff)
downloadgo-tangerine-313fe3861b3c338b3b6304adac46c86af7e2d52e.tar.gz
go-tangerine-313fe3861b3c338b3b6304adac46c86af7e2d52e.tar.zst
go-tangerine-313fe3861b3c338b3b6304adac46c86af7e2d52e.zip
fixed pow stuff
Diffstat (limited to 'eth')
-rw-r--r--eth/backend.go7
-rw-r--r--eth/protocol.go2
2 files changed, 6 insertions, 3 deletions
diff --git a/eth/backend.go b/eth/backend.go
index 0de0fcf4a..50fb70720 100644
--- a/eth/backend.go
+++ b/eth/backend.go
@@ -7,6 +7,7 @@ import (
"path"
"strings"
+ "github.com/ethereum/ethash"
"github.com/ethereum/go-ethereum/blockpool"
"github.com/ethereum/go-ethereum/core"
"github.com/ethereum/go-ethereum/crypto"
@@ -179,11 +180,13 @@ func New(config *Config) (*Ethereum, error) {
}
eth.chainManager = core.NewChainManager(db, eth.EventMux())
+ pow := ethash.New(eth.chainManager)
+
eth.txPool = core.NewTxPool(eth.EventMux())
- eth.blockProcessor = core.NewBlockProcessor(db, eth.txPool, eth.chainManager, eth.EventMux())
+ eth.blockProcessor = core.NewBlockProcessor(db, pow, eth.txPool, eth.chainManager, eth.EventMux())
eth.chainManager.SetProcessor(eth.blockProcessor)
eth.whisper = whisper.New()
- eth.miner = miner.New(keyManager.Address(), eth, config.MinerThreads)
+ eth.miner = miner.New(keyManager.Address(), eth, pow, config.MinerThreads)
hasBlock := eth.chainManager.HasBlock
insertChain := eth.chainManager.InsertChain
diff --git a/eth/protocol.go b/eth/protocol.go
index ee2316836..67ed8f9e5 100644
--- a/eth/protocol.go
+++ b/eth/protocol.go
@@ -14,7 +14,7 @@ import (
)
const (
- ProtocolVersion = 54
+ ProtocolVersion = 55
NetworkId = 0
ProtocolLength = uint64(8)
ProtocolMaxMsgSize = 10 * 1024 * 1024