Remove strerror deprecation remark

This commit is contained in:
ThePhD 2016-02-22 02:44:27 -05:00
parent 166771ae8d
commit 16c6f62fe3
2 changed files with 4 additions and 3 deletions

View File

@ -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;
}

View File

@ -504,7 +504,6 @@ TEST_CASE("advanced/call_lambdas", "A C++ lambda is exposed to lua and called")
REQUIRE(x == 9);
}
TEST_CASE("advanced/call_referenced_obj", "A C++ object is passed by pointer/reference_wrapper to lua and invoked") {
sol::state lua;