aboutsummaryrefslogtreecommitdiffstats
path: root/simulation/network.go
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2018-09-23 20:51:05 +0800
committerGitHub <noreply@github.com>2018-09-23 20:51:05 +0800
commit0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89 (patch)
tree626db6969aee92702001e5c9f3de56e2a439ccac /simulation/network.go
parent2c71e8448a9c03e924a7869351eebf2def1af057 (diff)
downloaddexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.tar
dexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.tar.gz
dexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.tar.bz2
dexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.tar.lz
dexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.tar.xz
dexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.tar.zst
dexon-consensus-0ab5a2d4f63ece79a4df32c6fb3ac710a954fd89.zip
core: run first DKG at startup. (#129)
Diffstat (limited to 'simulation/network.go')
-rw-r--r--simulation/network.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/simulation/network.go b/simulation/network.go
index d14f07e..938d785 100644
--- a/simulation/network.go
+++ b/simulation/network.go
@@ -153,6 +153,14 @@ func (n *network) SendDKGPrivateShare(
}
}
+// BroadcastDKGPrivateShare implements core.Network interface.
+func (n *network) BroadcastDKGPrivateShare(
+ prvShare *types.DKGPrivateShare) {
+ if err := n.trans.Broadcast(prvShare); err != nil {
+ panic(err)
+ }
+}
+
// ReceiveChan implements core.Network interface.
func (n *network) ReceiveChan() <-chan interface{} {
return n.toConsensus