From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp31.i.mail.ru (smtp31.i.mail.ru [94.100.177.91]) (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 75BAC469719 for ; Fri, 13 Nov 2020 12:31:48 +0300 (MSK) References: <20201112195121.191366-1-gorcunov@gmail.com> <20201112195121.191366-5-gorcunov@gmail.com> From: Serge Petrenko Message-ID: <2cd166c9-c35d-1653-cc00-7f5520721a49@tarantool.org> Date: Fri, 13 Nov 2020 12:31:47 +0300 MIME-Version: 1.0 In-Reply-To: <20201112195121.191366-5-gorcunov@gmail.com> Content-Type: text/plain; charset="utf-8"; format="flowed" Content-Transfer-Encoding: 8bit Content-Language: ru Subject: Re: [Tarantool-patches] [PATCH 04/11] txn: txn_commit_async -- drop redundant variable List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Cyrill Gorcunov , tml Cc: Vladislav Shpilevoy 12.11.2020 22:51, Cyrill Gorcunov пишет: > We use it once so it is simply redundant. > > Signed-off-by: Cyrill Gorcunov > --- > src/box/txn.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/src/box/txn.c b/src/box/txn.c > index a075c9ef0..64f01f4e0 100644 > --- a/src/box/txn.c > +++ b/src/box/txn.c > @@ -815,9 +815,8 @@ txn_commit_async(struct txn *txn) > if (req == NULL) > goto rollback; > > - bool is_sync = txn_has_flag(txn, TXN_WAIT_SYNC); > struct txn_limbo_entry *limbo_entry; > - if (is_sync) { > + if (txn_has_flag(txn, TXN_WAIT_SYNC)) { > /* > * We'll need this trigger for sync transactions later, > * but allocation failure is inappropriate after the entry LGTM -- Serge Petrenko