aboutsummaryrefslogtreecommitdiffstats
path: root/dex/handler.go
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2019-02-27 10:41:01 +0800
committerWei-Ning Huang <w@byzantine-lab.io>2019-06-12 17:27:22 +0800
commit2b2396b6bce0f21b515ac2d38556f6dca08b1770 (patch)
tree60d6c93689b54534ecc88bd1491bd82fa372b541 /dex/handler.go
parentedb1273cb08d56df41b30b1f2f2e113f9b4296e4 (diff)
downloadgo-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.tar
go-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.tar.gz
go-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.tar.bz2
go-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.tar.lz
go-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.tar.xz
go-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.tar.zst
go-tangerine-2b2396b6bce0f21b515ac2d38556f6dca08b1770.zip
core: sync to latest core (#214)
* vendor: sync to latest core * fix for single chain
Diffstat (limited to 'dex/handler.go')
-rw-r--r--dex/handler.go15
1 files changed, 6 insertions, 9 deletions
diff --git a/dex/handler.go b/dex/handler.go
index 474852913..4ffa01244 100644
--- a/dex/handler.go
+++ b/dex/handler.go
@@ -1005,9 +1005,8 @@ func (pm *ProtocolManager) BroadcastVote(vote *coreTypes.Vote) {
pm.cache.addVote(vote)
}
label := peerLabel{
- set: notaryset,
- chainID: vote.Position.ChainID,
- round: vote.Position.Round,
+ set: notaryset,
+ round: vote.Position.Round,
}
for _, peer := range pm.peers.PeersWithLabel(label) {
peer.AsyncSendVotes([]*coreTypes.Vote{vote})
@@ -1038,9 +1037,8 @@ func (pm *ProtocolManager) BroadcastRandomnessResult(
pm.cache.addRandomness(randomness)
// send to notary nodes first (direct)
label := peerLabel{
- set: notaryset,
- chainID: randomness.Position.ChainID,
- round: randomness.Position.Round,
+ set: notaryset,
+ round: randomness.Position.Round,
}
randomnesses := []*coreTypes.BlockRandomnessResult{randomness}
for _, peer := range pm.peers.PeersWithLabel(label) {
@@ -1104,9 +1102,8 @@ func (pm *ProtocolManager) BroadcastPullBlocks(
func (pm *ProtocolManager) BroadcastPullVotes(
pos coreTypes.Position) {
label := peerLabel{
- set: notaryset,
- chainID: pos.ChainID,
- round: pos.Round,
+ set: notaryset,
+ round: pos.Round,
}
for idx, peer := range pm.peers.PeersWithLabel(label) {
if idx >= maxPullVotePeers {