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 4692616F8EC9; Tue, 10 Mar 2026 17:21:36 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 4692616F8EC9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1773152496; bh=2TlwkvT7bmPx3ulHIFMOU65zjuXCESMml0e2PGzDiyI=; 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=MRvWnDecG72EGsNdbaEaxJrGZ1ZD4/dxTm1snGhsEg+QCNZXo0HB6RNtFprgkxiRS hwyQCuv3hCNmthm7mzr4kg4J/DDd9XwyR8HS7/3LwZfUyN584nyOqJa+9eMEBT9Kga WBf1solVChJpNZgmWg4kPuYGtlmondPF21lmx68k= Received: from send83.i.mail.ru (send83.i.mail.ru [89.221.237.178]) (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 C0DF516F8EC3 for ; Tue, 10 Mar 2026 17:21:35 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org C0DF516F8EC3 Received: by exim-smtp-695fc89d9f-6mvz7 with esmtpa (envelope-from ) id 1vzxxm-000000009MF-2z7H; Tue, 10 Mar 2026 17:21:35 +0300 Content-Type: multipart/alternative; boundary="------------nfFy6kLB04wCP2LdWz4PdvEe" Message-ID: Date: Tue, 10 Mar 2026 17:21:33 +0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Content-Language: en-US To: Sergey Kaplun Cc: tarantool-patches@dev.tarantool.org References: <20260302082317.4082-1-skaplun@tarantool.org> <26109d50-0770-4007-ba9e-1b2f747c8a3d@tarantool.org> In-Reply-To: X-Mailru-Src: smtp X-4EC0790: 10 X-7564579A: EEAE043A70213CC8 X-77F55803: 4F1203BC0FB41BD9B03C736E48BC2E6237753D1DE15B6F0800F06270A5E22174182A05F5380850404C228DA9ACA6FE27043F84B4F5583FC23DE06ABAFEAF6705BF46EAC68E9626A523EB4DE9956549DD9CAD6AA93C8D19D4 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE731D82F3F177D3BCDEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637AC83A81C8FD4AD23D82A6BABE6F325AC2E85FA5F3EDFCBAA7353EFBB553375665A08EF23E7B416AB1970A4C6530D80321219265DBD0E382E6511102AF4AE02E9389733CBF5DBD5E913377AFFFEAFD269176DF2183F8FC7C0B27420F9988F54058941B15DA834481FCF19DD082D7633A0EF3E4896CB9E6436389733CBF5DBD5E9D5E8D9A59859A8B6F459A8243F1D1D44CC7F00164DA146DA6F5DAA56C3B73B237318B6A418E8EAB86D1867E19FE14079C09775C1D3CA48CF3D321E7403792E342EB15956EA79C166A417C69337E82CC275ECD9A6C639B01B78DA827A17800CE76D0F27F7E6A6C418731C566533BA786AA5CC5B56E945C8DA X-C1DE0DAB: 0D63561A33F958A55008A1DC1B20E7D25002B1117B3ED69628D9569407AFAE45C638DF663A625AFA823CB91A9FED034534781492E4B8EEADEF0AF71940E62277BDAD6C7F3747799A X-C8649E89: 1C3962B70DF3F0AD73CAD6646DEDE1918E10F71CB4DF9F96AB70F9BE574AE9C625B6776AC983F447FC0B9F89525902EE6F57B2FD27647F25E66C117BDB76D6599BAB89912248B653E04EC32177B0BAB221748FB96D901FF5A30D60E61F1784E6C6E947F48E8030F1B8341EE9D5BE9A0AC1BD7F7FF1E9F93911458F2BFBBE01DD1F47E4E9500F820E8CD93680B12512CF4C41F94D744909CE2512F26BEC029E55448553D2254B8D95CD72808BE417F3B9E0E7457915DAA85F X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu53w8ahmwBjZKM/YPHZyZHvz5uv+WouB9+ObcCpyrx6l7KImUglyhkEat/+ysWwi0gdhEs0JGjl6ggRWTy1haxBpVdbIX1nthFXMZebaIdHP2ghjoIc/363UZI6Kf1ptIMVdbVVJCphTR/+82UMTEMw/M= X-DA7885C5: A688B987A59905C0F255D290C0D534F93C0950C8CE7E36448B1278BEBD4DBC6B906B325AAA15E12E5B1A4C17EAA7BC4BEF2421ABFA55128DAF83EF9164C44C7E X-Mailru-Sender: 689FA8AB762F7393DDD5FD59B456EAD2080200A78515D09D96857907B497CA15386C1B7A8A50D1C9EF86D5F70DA33880E41E8EF7A07863ECB274557F927329BE2DDF8182D28ACDB545BD1C3CC395C826B4A721A3011E896F X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH luajit] Fix reporting of an error during error handling. 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. --------------nfFy6kLB04wCP2LdWz4PdvEe Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Hi, Sergey! On 3/4/26 17:31, Sergey Kaplun wrote: >>> +-- OOM in the error handler. >>> +coroutine.wrap(function() >>> + local function errmem() local _ = {} end >>> + allocinject.enable_null_alloc() >>> + local st, msg = xpcall(error, errmem) >>> + allocinject.disable() >>> +test:ok(not st, 'OOM incorrect status') >>> + -- Prevent preallocated error message. >>> +test:ok(msg:match('error in ' .. 'error handling'), >>> + 'OOM incorrect errmsg: ' .. msg) >>> +end)() >>> + >>> +-- STKOV in the error handler. >> Why abbreviation is used? May be "stack overflow"? Feel free to ignore. > This is done to be consistent witht the OOM abbreviation above. > If you don't insist, I would leave them as is. Ok, let's leave as is. LGTM > >>> +coroutine.wrap(function() >>> + local function stkov() stkov() end >>> + local st, msg = xpcall(error, stkov) >>> +test:ok(not st, 'STKOV incorrect status') >>> + -- Prevent preallocated error message. >>> +test:ok(msg:match('error in ' .. 'error handling'), >>> + 'STKOV incorrect errmsg: ' .. msg) >>> +end)() >>> + >>> +test:done(true) > > --------------nfFy6kLB04wCP2LdWz4PdvEe Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 7bit

Hi, Sergey!

On 3/4/26 17:31, Sergey Kaplun wrote:


<snipped>

+-- OOM in the error handler.
+coroutine.wrap(function()
+  local function errmem() local _ = {} end
+  allocinject.enable_null_alloc()
+  local st, msg = xpcall(error, errmem)
+  allocinject.disable()
+test:ok(not st, 'OOM incorrect status')
+  -- Prevent preallocated error message.
+test:ok(msg:match('error in ' .. 'error handling'),
+          'OOM incorrect errmsg: ' .. msg)
+end)()
+
+-- STKOV in the error handler.
Why abbreviation is used? May be "stack overflow"? Feel free to ignore.
This is done to be consistent witht the OOM abbreviation above.
If you don't insist, I would leave them as is.
Ok, let's leave as is. LGTM

+coroutine.wrap(function()
+  local function stkov() stkov() end
+  local st, msg = xpcall(error, stkov)
+test:ok(not st, 'STKOV incorrect status')
+  -- Prevent preallocated error message.
+test:ok(msg:match('error in ' .. 'error handling'),
+          'STKOV incorrect errmsg: ' .. msg)
+end)()
+
+test:done(true)
<snipped>

--------------nfFy6kLB04wCP2LdWz4PdvEe--