Assert that paxos quorum is set

This commit is contained in:
Bryan Boreham committed 2016-03-24 12:06:59 +00:00
1 parent e6fd970920
commit cfa9b4f638
1 file changed
+3
+3
View File
@@ -128,6 +128,9 @@ func max(a uint, b uint) uint {
// simply a matter of gossipping a new proposal that supersedes all
// others.
func (node *Node) Propose() {
if node.quorum == 0 {
panic("Paxos node.Propose() called with no quorum set")
}
// Find the highest round number around
round := uint(0)