let build be possible with current (5.5.0) Lua
Lua 5.5.0 became the most-current Lua version on December 22, 2025
This commit is contained in:
10
src/nhlua.c
10
src/nhlua.c
@@ -2216,8 +2216,12 @@ nhl_init(nhl_sandbox_info *sbi)
|
||||
/* It would be nice to import EXPECTED from each build system. XXX */
|
||||
/* And it would be nice to do it only once, but it's cheap. */
|
||||
#ifndef NHL_VERSION_EXPECTED
|
||||
#if LUA_VERSION_NUM >= 505
|
||||
#define NHL_VERSION_EXPECTED 50500
|
||||
#else
|
||||
#define NHL_VERSION_EXPECTED 50406
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef NHL_SANDBOX
|
||||
if (NHL_VERSION_EXPECTED != LUA_VERSION_RELEASE_NUM) {
|
||||
@@ -2978,7 +2982,11 @@ nhlL_newstate(nhl_sandbox_info *sbi, const char *name)
|
||||
nud->sid = ++gl.lua_sid;
|
||||
}
|
||||
|
||||
lua_State *L = lua_newstate(nhl_alloc, nud);
|
||||
lua_State *L = lua_newstate(nhl_alloc, nud
|
||||
#if LUA_VERSION_NUM >= 505
|
||||
, 0
|
||||
#endif
|
||||
);
|
||||
if (!L)
|
||||
panic("NULL lua_newstate");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user