mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
Merge pull request #5645 from gyuho/wal_simple
wal: simplify boolean return
This commit is contained in:
commit
667093bbd1
@ -575,10 +575,7 @@ func mustSync(st, prevst raftpb.HardState, entsnum int) bool {
|
|||||||
// currentTerm
|
// currentTerm
|
||||||
// votedFor
|
// votedFor
|
||||||
// log entries[]
|
// log entries[]
|
||||||
if entsnum != 0 || st.Vote != prevst.Vote || st.Term != prevst.Term {
|
return entsnum != 0 || st.Vote != prevst.Vote || st.Term != prevst.Term
|
||||||
return true
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func closeAll(rcs ...io.ReadCloser) error {
|
func closeAll(rcs ...io.ReadCloser) error {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user