fix(build): issues with s390x CI

Does not fix everything, but at least let's test run to finish before
timeout
This commit is contained in:
bfredl
2024-01-08 14:34:49 +01:00
parent 0346666f71
commit 176bfea135
2 changed files with 9 additions and 4 deletions

View File

@@ -185,7 +185,12 @@ static mmfile_t get_string_arg(lua_State *lstate, int idx)
luaL_argerror(lstate, idx, "expected string");
}
mmfile_t mf;
mf.ptr = (char *)lua_tolstring(lstate, idx, (size_t *)&mf.size);
size_t size;
mf.ptr = (char *)lua_tolstring(lstate, idx, &size);
if (size > INT_MAX) {
luaL_argerror(lstate, idx, "string too long");
}
mf.size = (int)size;
return mf;
}