From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtpng3.m.smailru.net (smtpng3.m.smailru.net [94.100.177.149]) (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 3C58941D954 for ; Fri, 3 Jul 2020 09:33:24 +0300 (MSK) Received: by smtpng3.m.smailru.net with esmtpa (envelope-from ) id 1jrFGF-0003jC-Qw for tarantool-patches@dev.tarantool.org; Fri, 03 Jul 2020 09:33:24 +0300 From: Aleksandr Lyapunov Date: Fri, 3 Jul 2020 09:33:07 +0300 Message-Id: <1593757997-4145-6-git-send-email-alyapunov@tarantool.org> In-Reply-To: <1593757997-4145-1-git-send-email-alyapunov@tarantool.org> References: <1593757997-4145-1-git-send-email-alyapunov@tarantool.org> Subject: [Tarantool-patches] [PATCH 05/15] tx: save txn in txn_stmt List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: tarantool-patches@dev.tarantool.org --- src/box/txn.c | 1 + src/box/txn.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/src/box/txn.c b/src/box/txn.c index 1235201..71e732c 100644 --- a/src/box/txn.c +++ b/src/box/txn.c @@ -100,6 +100,7 @@ txn_stmt_new(struct region *region) } /* Initialize members explicitly to save time on memset() */ + stmt->txn = in_txn(); stmt->space = NULL; stmt->old_tuple = NULL; stmt->new_tuple = NULL; diff --git a/src/box/txn.h b/src/box/txn.h index 3f6d79d..5b264f0 100644 --- a/src/box/txn.h +++ b/src/box/txn.h @@ -85,6 +85,8 @@ struct txn_stmt { /** A linked list of all statements. */ struct stailq_entry next; + /** Owner of that statement. */ + struct txn *txn; /** Undo info. */ struct space *space; struct tuple *old_tuple; -- 2.7.4