From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 3151D6EC5B; Tue, 30 Mar 2021 14:21:53 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 3151D6EC5B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1617103313; bh=0qH3mywtsKtG4yImRSwh2IlzbCnfL62/9fkAjR5VtNE=; h=To:Cc:Date:Subject:List-Id:List-Unsubscribe:List-Archive: List-Post:List-Help:List-Subscribe:From:Reply-To:From; b=DriQPMyWrX8Vqww4J89/iBL1QFGOmS69c/H7f/LcmIrsjHm2XSDVnazA5KfHZeCyh XxwyKHl0vQKnI3yBKfFMPjZNGCCLOB7CMWw4WUo3OsLJ2xHbKSzbS8prlte9e0wDw2 6WFWClM5oKjifrEj0tT8gtKrdhGGaPnYEFTrYusU= Received: from smtp59.i.mail.ru (smtp59.i.mail.ru [217.69.128.39]) (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 06D546EC5B for ; Tue, 30 Mar 2021 14:21:51 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 06D546EC5B Received: by smtp59.i.mail.ru with esmtpa (envelope-from ) id 1lRCRT-0006MI-3N; Tue, 30 Mar 2021 14:21:51 +0300 To: v.shpilevoy@tarantool.org Cc: tarantool-patches@dev.tarantool.org Date: Tue, 30 Mar 2021 14:21:50 +0300 Message-Id: X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD9ED7173E37F4E3294CA3588DDE0233B0D17711AF1EA2D7DB9182A05F538085040EBE8F2BA8A993D2FF6BFBF8006CDDC4765301B9356CC3E6717B97874C8C6B73B X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7922E451CE6E839B1EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F79006379A6B93796C91DCB58638F802B75D45FF914D58D5BE9E6BC131B5C99E7648C95CE99938B3FD79E1DF8561E727245533BD1D1513DF7912FD43A471835C12D1D9774AD6D5ED66289B5259CC434672EE6371117882F4460429724CE54428C33FAD30A8DF7F3B2552694AC26CFBAC0749D213D2E47CDBA5A9658359CC434672EE6371117882F4460429728AD0CFFFB425014E868A13BD56FB6657D81D268191BDAD3DC09775C1D3CA48CF81B3E0F64AD3EF5776E601842F6C81A12EF20D2F80756B5F7E9C4E3C761E06A776E601842F6C81A127C277FBC8AE2E8BFF1C396FDA0701F33AA81AA40904B5D9DBF02ECDB25306B2201CA6A4E26CD07C3BBE47FD9DD3FB595F5C1EE8F4F765FCA83251EDC214901ED5E8D9A59859A8B69C803D8CAE72B18A089D37D7C0E48F6C5571747095F342E88FB05168BE4CE3AF X-C1DE0DAB: C20DE7B7AB408E4181F030C43753B8186998911F362727C414F749A5E30D975CE99938B3FD79E1DF8561E727245533BD1D1513DF7912FD439C2B6934AE262D3EE7EAB7254005DCED556CBE7F905700A49510FB958DCE06DB6ED91DBE5ABE359ADBCB5631A0A9D21F1B2EFE7B39F7738393EDB24507CE13387DFF0A840B692CF8 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34682FD2D2951524C51F7EEE91443EF71B52740DD82C3DA8984C98D18CB7E5FF293EEEDE17503CA3E11D7E09C32AA3244C92437A3DD183DBB509890A3E9ADA2C2369B6CAE0477E908D729B2BEF169E0186 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojbL9S8ysBdXhvv95JXCZNDmgCjIo0uAG2 X-Mailru-Sender: 5C3750E245F362008BC1685FEC6306EDD612900DDD2413F4F6BFBF8006CDDC47B9A8FEFFB5F7F2D55105BD0848736F9966FEC6BF5C9C28D97E07721503EA2E00ED97202A5A4E92BF7402F9BA4338D657ED14614B50AE0675 X-Mras: Ok Subject: [Tarantool-patches] [PATCH v1 0/2] sql: ignore \0 in string passed to user function X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Mergen Imeev via Tarantool-patches Reply-To: imeevma@tarantool.org Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Currently, string passed to user-defined function from SQL can be cropped in case it contains '\0'. This patch-set fixes this behaviour. https://github.com/tarantool/tarantool/issues/5938 https://github.com/tarantool/tarantool/tree/imeevma/gh-5938-wrong-string-length Mergen Imeev (2): sql: ignore \0 in string passed to C-function sql: ignore \0 in string passed to Lua-function src/box/sql/func.c | 6 ++- test/CMakeLists.txt | 1 + test/sql-tap/CMakeLists.txt | 2 + test/sql-tap/gh-5938-wrong-string-length.c | 42 +++++++++++++++++ .../gh-5938-wrong-string-length.test.lua | 45 +++++++++++++++++++ 5 files changed, 94 insertions(+), 2 deletions(-) create mode 100644 test/sql-tap/CMakeLists.txt create mode 100644 test/sql-tap/gh-5938-wrong-string-length.c create mode 100755 test/sql-tap/gh-5938-wrong-string-length.test.lua -- 2.25.1