core, eth: enforce network split post DAO hard-fork

This commit is contained in:
Péter Szilágyi
2016-07-08 20:59:11 +03:00
parent a87089fd2d
commit 7f00e8c033
4 changed files with 141 additions and 7 deletions

View File

@ -59,10 +59,12 @@ type peer struct {
*p2p.Peer
rw p2p.MsgReadWriter
version int // Protocol version negotiated
head common.Hash
td *big.Int
lock sync.RWMutex
version int // Protocol version negotiated
forkDrop *time.Timer // Timed connection dropper if forks aren't validated in time
head common.Hash
td *big.Int
lock sync.RWMutex
knownTxs *set.Set // Set of transaction hashes known to be known by this peer
knownBlocks *set.Set // Set of block hashes known to be known by this peer