From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp51.i.mail.ru (smtp51.i.mail.ru [94.100.177.111]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 683F6430412 for ; Wed, 26 Aug 2020 10:53:07 +0300 (MSK) From: Serge Petrenko Date: Wed, 26 Aug 2020 10:52:39 +0300 Message-Id: In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [RAFT 07/10] [tosquash] raft: rename curr_leader to leader List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: v.shpilevoy@tarantool.org, gorcunov@gmail.com, sergos@tarantool.org Cc: tarantool-patches@dev.tarantool.org From: Vladislav Shpilevoy Because it will be consistent with 'vote', which is not 'curr_vote'. --- src/box/raft.c | 2 +- src/box/raft.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/box/raft.c b/src/box/raft.c index 1d25459e9..714a1518a 100644 --- a/src/box/raft.c +++ b/src/box/raft.c @@ -40,7 +40,7 @@ struct raft raft = { .term = 0, .vote = 0, - .curr_leader = 0, + .leader = 0, .state = RAFT_STATE_NONE, }; diff --git a/src/box/raft.h b/src/box/raft.h index c95a51873..927aa8f5f 100644 --- a/src/box/raft.h +++ b/src/box/raft.h @@ -46,7 +46,7 @@ enum raft_state { struct raft { uint64_t term; uint32_t vote; - uint32_t curr_leader; + uint32_t leader; enum raft_state state; }; -- 2.20.1 (Apple Git-117)