[PATCH] log: Don't compute next_log on network replays
Export this patch
Signed-off-by: Louis Solofrizzo <lsolofrizzo@scaleway.com>
---
log.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/log.c b/log.c
index 58610a0..03c043c 100644
--- a/log.c
+++ b/log.c
@@ -664,8 +664,10 @@ void libfloat_append_entries_response(libfloat_ctx_t *ctx, libfloat_rpc_append_e
node->next_log_to_send = 1;
return;
}
+
ERROR(ctx, "libfloat_append_entries_response: node %d: received current_index (%u) older than replicated_log (%u)",
node->id, resp->current_index, node->replicated_log);
+ return;
}
node->next_log_to_send = max(resp->current_index + 1, 1);
--
2.35.0
LG
LG
--
Michael Bonfils
htps://www.murlock.org/
‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐