From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id E571A2A67E for ; Tue, 26 Mar 2019 13:09:00 -0400 (EDT) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing.freelists.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5qksiLl9Lv5A for ; Tue, 26 Mar 2019 13:09:00 -0400 (EDT) Received: from smtp20.mail.ru (smtp20.mail.ru [94.100.179.251]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTPS id 9A1D428768 for ; Tue, 26 Mar 2019 13:09:00 -0400 (EDT) From: Vladislav Shpilevoy Subject: [tarantool-patches] Re: [PATCH v2 3/7] sql: refactor sql_src_list_append to set diag References: <390fc2f46ba80994aa4ebf97d3aeb8ea8c26c71c.1551265819.git.kshcherbatov@tarantool.org> <4dcd389e-2388-d145-a82c-2cabc2b9ed15@tarantool.org> <8743fe4b-6485-9b72-dd40-e4d2ecab5801@tarantool.org> <2c6214c0-dc40-bb33-283b-781234ad3360@tarantool.org> Message-ID: <5767df44-9cbd-1959-9268-a82f55e4fbeb@tarantool.org> Date: Tue, 26 Mar 2019 20:08:58 +0300 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: tarantool-patches-bounce@freelists.org Errors-to: tarantool-patches-bounce@freelists.org Reply-To: tarantool-patches@freelists.org List-Help: List-Unsubscribe: List-software: Ecartis version 1.0.0 List-Id: tarantool-patches List-Subscribe: List-Owner: List-post: List-Archive: To: tarantool-patches@freelists.org, Kirill Shcherbatov Hi! Thanks for the fixes! Please, look at the diff below and on the branch. ============================================================= commit 5edf345d82d7954944a1d7c7464b724821829388 Author: Vladislav Shpilevoy Date: Mon Mar 25 15:09:13 2019 +0300 Review fixes diff --git a/src/box/sql/parse.y b/src/box/sql/parse.y index ead71dfc0..9bd948bb4 100644 --- a/src/box/sql/parse.y +++ b/src/box/sql/parse.y @@ -617,7 +617,7 @@ seltablist(A) ::= stl_prefix(A) LP seltablist(F) RP %type fullname {SrcList*} %destructor fullname {sqlSrcListDelete(pParse->db, $$);} fullname(A) ::= nm(X). { - /*A-overwrites-X. */ + /* A-overwrites-X. */ A = sql_src_list_append(pParse->db,0,&X); if (A == NULL) { pParse->is_aborted = true; diff --git a/src/box/sql/sqlInt.h b/src/box/sql/sqlInt.h index b6c89893a..6dd1c58a7 100644 --- a/src/box/sql/sqlInt.h +++ b/src/box/sql/sqlInt.h @@ -3459,12 +3459,8 @@ sql_src_list_new(struct sql *db); * @param db The database connection. * @param list Append to this SrcList. NULL creates a new SrcList. * @param name_token Token representing table name. - * @retval Not NULL SrcList pointer is returned. The returned - * SrcList might be the same as the list that was input - * or it might be a new one. - * @retval NULL Otherwise. The diag message is set. The prior - * value of list that is input to this routine is - * automatically freed. + * @retval Not NULL A new SrcList or updated @a list. + * @retval NULL Error. A diag message is set. @A list is deleted. */ struct SrcList * sql_src_list_append(struct sql *db, struct SrcList *list,