aboutsummaryrefslogtreecommitdiffstats
path: root/core/agreement.go
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2019-03-24 14:43:33 +0800
committerJimmy Hu <jimmy.hu@dexon.org>2019-03-24 16:17:26 +0800
commitfa3b5a29499739e90b3cf17f9a0cf60a72a64fc0 (patch)
tree792bd67c70e9b40f871c9cc0f03345ec70793427 /core/agreement.go
parentd077a35470cf4b6e7c82bd4b03a1f2b87b0f9add (diff)
downloadtangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.tar
tangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.tar.gz
tangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.tar.bz2
tangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.tar.lz
tangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.tar.xz
tangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.tar.zst
tangerine-consensus-fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0.zip
core: fix required vote calculations (#513)
Diffstat (limited to 'core/agreement.go')
-rw-r--r--core/agreement.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/agreement.go b/core/agreement.go
index 1919830..16f36bc 100644
--- a/core/agreement.go
+++ b/core/agreement.go
@@ -174,7 +174,7 @@ func (a *agreement) restart(
a.data.votes[1] = newVoteListMap()
a.data.period = 2
a.data.blocks = make(map[types.NodeID]*types.Block)
- a.data.requiredVote = len(notarySet)/3*2 + 1
+ a.data.requiredVote = len(notarySet)*2/3 + 1
a.data.leader.restart(crs)
a.data.lockValue = types.NullBlockHash
a.data.lockIter = 0