Re: [ovs-dev] [PATCH 1/4] raft.c: Move raft_reset_ping_timer() out of the loop.

2019-08-21 Thread Ben Pfaff
On Tue, Aug 13, 2019 at 09:23:19AM -0700, Han Zhou wrote:
> From: Han Zhou 
> 
> Fixes: commit 5a9b53a5 ("ovsdb raft: Fix duplicated transaction execution 
> when leader failover.")
> Signed-off-by: Han Zhou 

Thanks!  I applied this to master and branch-2.12.
___
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev


[ovs-dev] [PATCH 1/4] raft.c: Move raft_reset_ping_timer() out of the loop.

2019-08-13 Thread Han Zhou
From: Han Zhou 

Fixes: commit 5a9b53a5 ("ovsdb raft: Fix duplicated transaction execution when 
leader failover.")
Signed-off-by: Han Zhou 
---
 ovsdb/raft.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ovsdb/raft.c b/ovsdb/raft.c
index c60ef41..1c38b3b 100644
--- a/ovsdb/raft.c
+++ b/ovsdb/raft.c
@@ -1816,8 +1816,8 @@ raft_run(struct raft *raft)
 && now - cmd->timestamp > ELECTION_BASE_MSEC * 2) {
 raft_command_complete(raft, cmd, RAFT_CMD_TIMEOUT);
 }
-raft_reset_ping_timer(raft);
 }
+raft_reset_ping_timer(raft);
 }
 
 /* Do this only at the end; if we did it as soon as we set raft->left or
-- 
2.1.0

___
dev mailing list
d...@openvswitch.org
https://mail.openvswitch.org/mailman/listinfo/ovs-dev