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 B406DC6A6F1; Thu, 15 Aug 2024 10:34:07 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B406DC6A6F1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1723707247; bh=/i5apYUwGw3trB7WrSnf24nzRswjWyojR5Jd/TtbxpQ=; h=Date:To:Cc:References:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=IRXkmkr+3Wozk9uRJKbbILutY2o+y3zN4LY93XBF2aGMQFUB/yYUn/1biScabqXAN NHXNF8F7eyzfrkAYOhOYlZKKavcI70x1gcC6ZOFjJEzCHstDDVae/l2Bzkgb2P5FAv HRHfmYNw9ULxlXIlEtAvJ2FITA1T0Eia9JCRlRsk= Received: from smtp30.i.mail.ru (smtp30.i.mail.ru [95.163.41.71]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 9477FC6A6E9 for ; Thu, 15 Aug 2024 10:34:06 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 9477FC6A6E9 Received: by smtp30.i.mail.ru with esmtpa (envelope-from ) id 1seUzk-00000004wgj-00ah; Thu, 15 Aug 2024 10:34:04 +0300 Content-Type: multipart/alternative; boundary="------------HfuVyJOtPIFZ88g0V5gEoQ2a" Message-ID: <3a3f7758-026b-437b-951b-4cc2ed4f2d2d@tarantool.org> Date: Thu, 15 Aug 2024 10:34:03 +0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Sergey Kaplun Cc: Sergey Bronnikov , tarantool-patches@dev.tarantool.org References: <43db36be-eb47-48ce-bec8-7326f3f9f24e@tarantool.org> In-Reply-To: X-Mailru-Src: smtp X-4EC0790: 10 X-7564579A: 646B95376F6C166E X-77F55803: 4F1203BC0FB41BD9D7B6E71A78C20FB9969443CE02F730EADE0A60473FBA4966182A05F5380850402025F09C2114C0D7D4FF92D56319F19771F4ECBF2A8CB6C3E1B8B854C4154FF996A23FDDE6D060B7 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7A3295C83650092F9EA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637FD60A286D0BA57028638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D81AA4ED4247F88FC35252F261DD976FA4859BC93DA502D8B4CC7F00164DA146DAFE8445B8C89999728AA50765F790063783E00425F71A4181389733CBF5DBD5E9C8A9BA7A39EFB766F5D81C698A659EA7CC7F00164DA146DA9985D098DBDEAEC8B861051D4BA689FCF6B57BC7E6449061A352F6E88A58FB86F5D81C698A659EA73AA81AA40904B5D9A18204E546F3947C5E3BF8C76DC23F74C0837EA9F3D197644AD6D5ED66289B523666184CF4C3C14F6136E347CC761E07725E5C173C3A84C31B9641C7FFD9FDBABA3038C0950A5D36B5C8C57E37DE458B330BD67F2E7D9AF16D1867E19FE14079C09775C1D3CA48CF3D321E7403792E342EB15956EA79C166A417C69337E82CC275ECD9A6C639B01B78DA827A17800CE760D144E5727D8455731C566533BA786AA5CC5B56E945C8DA X-C1DE0DAB: 0D63561A33F958A569510876EC82368E5002B1117B3ED6964974AD0096BABDF78B25839F35DFE037823CB91A9FED034534781492E4B8EEADCAFEFF123806BC82BDAD6C7F3747799A X-C8649E89: 1C3962B70DF3F0ADE00A9FD3E00BEEDF3FED46C3ACD6F73ED3581295AF09D3DF87807E0823442EA2ED31085941D9CD0AF7F820E7B07EA4CF8AB0799ADB5F2C38067B9D0E70AA7281D837F6CF8EFC9BA79C1A8678258BC72A2DF5FAC740BFE7CD470327EB0AC8E693A0BA169D8EF1159B9C6F242382BEA051C7BDB171AEAC29855F4332CA8FE04980913E6812662D5F2AB9AF64DB4688768036DF5FE9C0001AF333F2C28C22F508233FCF178C6DD14203 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojD5rM0r3KxnEzNP90h/fzoA== X-Mailru-Sender: 520A125C2F17F0B1E52FEF5D219D61402AF118678A3A0DE80FCEB2BF21D9B3D1C66066E32560C3210152A3D17938EB451EB5A0BCEC6A560B3DDE9B364B0DF289BE2DA36745F2EEB5CEBA01FB949A1F1EEAB4BC95F72C04283CDA0F3B3F5B9367 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH luajit 2/2][v2] FFI: Turn FFI finalizer table into a proper GC root. 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: Sergey Bronnikov via Tarantool-patches Reply-To: Sergey Bronnikov Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" This is a multi-part message in MIME format. --------------HfuVyJOtPIFZ88g0V5gEoQ2a Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Hello, Sergey, On 12.08.2024 16:17, Sergey Kaplun wrote: >> >>> Also, please add here comment about `sizeof(buff) - 1` too. > Please add a comment that the terminating '\0' is considered by parser > as part of the input, so we must chomp it. Updated: --- a/test/tarantool-c-tests/lj-1168-unmarked-finalizer-tab.test.c +++ b/test/tarantool-c-tests/lj-1168-unmarked-finalizer-tab.test.c @@ -89,6 +89,10 @@ unmarked_finalizer_tab_gcmark(void *test_state)         /* Not trigger GC during `lua_openffi()`. */         lua_gc(L, LUA_GCSTOP, 0); +       /* +        * The terminating '\0' is considered by parser as part of +        * the input, so we must chomp it. +        */         int res = luaL_loadbufferx(L, buff, sizeof(buff) - 1,                                    "test_chunk", "t");         if (res != LUA_OK) { > > > --------------HfuVyJOtPIFZ88g0V5gEoQ2a Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit

Hello, Sergey,


On 12.08.2024 16:17, Sergey Kaplun wrote:


<snipped>


Also, please add here comment about `sizeof(buff) - 1` too.
Please add a comment that the terminating '\0' is considered by parser
as part of the input, so we must chomp it.

Updated:


--- a/test/tarantool-c-tests/lj-1168-unmarked-finalizer-tab.test.c
+++ b/test/tarantool-c-tests/lj-1168-unmarked-finalizer-tab.test.c
@@ -89,6 +89,10 @@ unmarked_finalizer_tab_gcmark(void *test_state)
        /* Not trigger GC during `lua_openffi()`. */
        lua_gc(L, LUA_GCSTOP, 0);
 
+       /*
+        * The terminating '\0' is considered by parser as part of
+        * the input, so we must chomp it.
+        */
        int res = luaL_loadbufferx(L, buff, sizeof(buff) - 1,
                                   "test_chunk", "t");
        if (res != LUA_OK) {



        
<snipped>

--------------HfuVyJOtPIFZ88g0V5gEoQ2a--