mirror of
https://github.com/gogrlx/nats-server.git
synced 2026-04-17 11:24:44 -07:00
Off-by-one on RAFT pindex
This commit is contained in:
@@ -2873,7 +2873,7 @@ func (n *raft) processAppendEntry(ae *appendEntry, sub *subscription) {
|
||||
|
||||
if ae.pterm != n.pterm || ae.pindex != n.pindex {
|
||||
// Check if this is a lower index than what we were expecting.
|
||||
if ae.pindex < n.pindex {
|
||||
if ae.pindex <= n.pindex {
|
||||
n.debug("AppendEntry detected pindex less than ours: %d:%d vs %d:%d", ae.pterm, ae.pindex, n.pterm, n.pindex)
|
||||
var ar *appendEntryResponse
|
||||
|
||||
|
||||
Reference in New Issue
Block a user