mirror of
https://github.com/ThePhD/sol2.git
synced 2024-03-22 13:10:44 +08:00
Remove strerror deprecation remark
This commit is contained in:
parent
166771ae8d
commit
16c6f62fe3
@ -307,11 +307,13 @@ inline int luaL_fileresult(lua_State *L, int stat, const char *fname) {
|
||||
return 1;
|
||||
}
|
||||
else {
|
||||
char buf[1024];
|
||||
strerror_s(buf, 1024, en);
|
||||
lua_pushnil(L);
|
||||
if (fname)
|
||||
lua_pushfstring(L, "%s: %s", fname, strerror(en));
|
||||
lua_pushfstring(L, "%s: %s", fname, buf);
|
||||
else
|
||||
lua_pushstring(L, strerror(en));
|
||||
lua_pushstring(L, buf);
|
||||
lua_pushnumber(L, (lua_Number)en);
|
||||
return 3;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user