From b50c93e4c3f094f517b6384e81aa9117da10b78d Mon Sep 17 00:00:00 2001 From: Thijs Schreijer Date: Fri, 12 Apr 2013 11:37:53 +0200 Subject: 5.2 compatibility for the launcher wrapper. --- src/bin/rclauncher.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/bin/rclauncher.c b/src/bin/rclauncher.c index 4a99c491..60284638 100644 --- a/src/bin/rclauncher.c +++ b/src/bin/rclauncher.c @@ -35,8 +35,7 @@ static int runlua (lua_State *L, const char *lua_string, int argc, char *argv[]) int err_func; int err; - lua_pushliteral(L, "debug"); - lua_rawget(L, LUA_GLOBALSINDEX); /* get traceback function */ + lua_getglobal(L, "debug"); lua_pushliteral(L, "traceback"); lua_gettable(L, -2); err_func = lua_gettop (L); @@ -90,7 +89,7 @@ int main (int argc, char *argv[]) { TCHAR lua_wstring[4098]; #endif char lua_string[4098]; - lua_State *L = lua_open(); + lua_State *L = luaL_newstate(); (void)argc; /* avoid "unused parameter" warning */ luaL_openlibs(L); lua_newtable(L); // create arg table -- cgit v1.2.3-55-g6feb