|
|
|
@ -187,18 +187,10 @@ func (consensus *Consensus) getLeaderPubKey() *bls_cosi.PublicKeyWrapper { |
|
|
|
|
return consensus.LeaderPubKey |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
func (consensus *Consensus) getLeaderPubKey() *bls_cosi.PublicKeyWrapper { |
|
|
|
|
return consensus.LeaderPubKey |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
func (consensus *Consensus) getLeaderPubKey() *bls_cosi.PublicKeyWrapper { |
|
|
|
|
return consensus.LeaderPubKey |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
func (consensus *Consensus) SetLeaderPubKey(pub *bls_cosi.PublicKeyWrapper) { |
|
|
|
|
consensus.pubKeyLock.Lock() |
|
|
|
|
consensus.LeaderPubKey = pub |
|
|
|
|
consensus.pubKeyLock.Unlock() |
|
|
|
|
consensus.mutex.Lock() |
|
|
|
|
defer consensus.mutex.Unlock() |
|
|
|
|
consensus.setLeaderPubKey(pub) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
func (consensus *Consensus) setLeaderPubKey(pub *bls_cosi.PublicKeyWrapper) { |
|
|
|
|