Skip to content

Commit b78e2a7

Browse files
committed
Make raft peer forget about the message which is being received if the leader sends a heartbeat.
1 parent 3f57431 commit b78e2a7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/raft.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -955,6 +955,7 @@ static void raft_handle_update(raft_t r, raft_msg_update_t *m) {
955955
}
956956
} else {
957957
// just a heartbeat
958+
e->bytes = 0;
958959
}
959960

960961
if (RAFT_LOG_LAST_INDEX(r) >= 0) {

0 commit comments

Comments
 (0)