<!DOCTYPE html>
<html data-lt-installed="true">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body style="padding-bottom: 1px;">
    <p>LGTM, thanks!<br>
    </p>
    <div class="moz-cite-prefix">On 9/9/25 12:44, Sergey Kaplun wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:aL_25Wbb7dfGWsXk@root">
      <pre wrap="" class="moz-quote-pre">Hi, Sergey!
Thanks for the review!
Fixed your comment and force-pushed the branch.

On 09.09.25, Sergey Bronnikov wrote:
</pre>
      <blockquote type="cite">
        <pre wrap="" class="moz-quote-pre">Hi, Sergey,

thanks for the patch! LGTM with a minor comment.

Sergey

On 8/19/25 10:40, Sergey Kaplun wrote:
</pre>
      </blockquote>
      <pre wrap="" class="moz-quote-pre">
<snipped>

</pre>
      <blockquote type="cite">
        <blockquote type="cite">
          <pre wrap="" class="moz-quote-pre">+        /*
+        * Check that there is no crash and the limit is small enough.
+        */
+       lua_State *L = lua_newstate(limited_alloc_f, NULL);
</pre>
        </blockquote>
        <pre wrap="" class="moz-quote-pre">s/lua_State/const lua_State/
</pre>
      </blockquote>
      <pre wrap="" class="moz-quote-pre">
Fixed, thanks!

===================================================================
diff --git a/test/tarantool-c-tests/lj-1248-close-state-early-OOM.test.c b/test/tarantool-c-tests/lj-1248-close-state-early-OOM.test.c
index 6c9cb2ca..fe91d5e9 100644
--- a/test/tarantool-c-tests/lj-1248-close-state-early-OOM.test.c
+++ b/test/tarantool-c-tests/lj-1248-close-state-early-OOM.test.c
@@ -49,7 +49,7 @@ static int limited_memory_on_lua_newstate(void *test_state)
         /*
          * Check that there is no crash and the limit is small enough.
          */
-        lua_State *L = lua_newstate(limited_alloc_f, NULL);
+        const lua_State *L = lua_newstate(limited_alloc_f, NULL);
         assert_true(L == NULL);
         return TEST_EXIT_SUCCESS;
 #endif
===================================================================

</pre>
      <blockquote type="cite">
        <blockquote type="cite">
          <pre wrap="" class="moz-quote-pre">+        assert_true(L == NULL);
+       return TEST_EXIT_SUCCESS;
+#endif
+}
+
+#ifndef LJ_NO_UNWIND
+#  define LJ_NO_UNWIND 0
+#endif
+
+int main(void)
+{
+       /* <a class="moz-txt-link-freetext" href="Seehttps://github.com/LuaJIT/LuaJIT/issues/1311">Seehttps://github.com/LuaJIT/LuaJIT/issues/1311</a>. */
+       if (!LJ_NO_UNWIND)
+               return skip_all("Disabled for external unwinding build due to #1311");
+       const struct test_unit tgroup[] = {
+               test_unit_def(limited_memory_on_lua_newstate),
+       };
+       return test_run_group(tgroup, NULL);
+}
</pre>
        </blockquote>
      </blockquote>
      <pre wrap="" class="moz-quote-pre">
</pre>
    </blockquote>
  </body>
  <lt-container></lt-container>
</html>