diff options
author | Jimmy Hu <jimmy.hu@dexon.org> | 2019-03-29 13:00:55 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@byzantine-lab.io> | 2019-06-15 22:09:55 +0800 |
commit | a2403c5a125e4939a16e11ba10fadfabe6bbd136 (patch) | |
tree | f2fe598d54074ddd9e5a3ddd352484eaa2858e53 /dex/handler.go | |
parent | 41193d921118b4bdef5f0a1a5b7349a4c58abe94 (diff) | |
download | go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.tar go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.tar.gz go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.tar.bz2 go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.tar.lz go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.tar.xz go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.tar.zst go-tangerine-a2403c5a125e4939a16e11ba10fadfabe6bbd136.zip |
dex: fix initial build connection bug (#311)
Diffstat (limited to 'dex/handler.go')
-rw-r--r-- | dex/handler.go | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/dex/handler.go b/dex/handler.go index 6d0746d2f..161f4a4d8 100644 --- a/dex/handler.go +++ b/dex/handler.go @@ -1302,10 +1302,11 @@ func (pm *ProtocolManager) SetReceiveCoreMessage(enabled bool) { // a loop keep building and maintaining peers in notary set. // TODO: finish this func (pm *ProtocolManager) peerSetLoop() { - log.Debug("ProtocolManager: started peer set loop") - round := pm.gov.Round() - log.Trace("ProtocolManager: startup round", "round", round) + resetCount := pm.gov.DKGResetCount(round) + log.Debug("ProtocolManager: startup round", + "round", round, + "reset", resetCount) if round < dexCore.DKGDelayRound { for i := round; i <= dexCore.DKGDelayRound; i++ { @@ -1319,8 +1320,8 @@ func (pm *ProtocolManager) peerSetLoop() { if CRSRound > round { pm.peers.BuildConnection(CRSRound) round = CRSRound + resetCount = pm.gov.DKGResetCount(round) } - resetCount := uint64(0) for { select { |