diff options
Diffstat (limited to 'src/bin')
| -rw-r--r-- | src/bin/rclauncher.c | 5 |
1 files 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[]) | |||
| 35 | int err_func; | 35 | int err_func; |
| 36 | int err; | 36 | int err; |
| 37 | 37 | ||
| 38 | lua_pushliteral(L, "debug"); | 38 | lua_getglobal(L, "debug"); |
| 39 | lua_rawget(L, LUA_GLOBALSINDEX); /* get traceback function */ | ||
| 40 | lua_pushliteral(L, "traceback"); | 39 | lua_pushliteral(L, "traceback"); |
| 41 | lua_gettable(L, -2); | 40 | lua_gettable(L, -2); |
| 42 | err_func = lua_gettop (L); | 41 | err_func = lua_gettop (L); |
| @@ -90,7 +89,7 @@ int main (int argc, char *argv[]) { | |||
| 90 | TCHAR lua_wstring[4098]; | 89 | TCHAR lua_wstring[4098]; |
| 91 | #endif | 90 | #endif |
| 92 | char lua_string[4098]; | 91 | char lua_string[4098]; |
| 93 | lua_State *L = lua_open(); | 92 | lua_State *L = luaL_newstate(); |
| 94 | (void)argc; /* avoid "unused parameter" warning */ | 93 | (void)argc; /* avoid "unused parameter" warning */ |
| 95 | luaL_openlibs(L); | 94 | luaL_openlibs(L); |
| 96 | lua_newtable(L); // create arg table | 95 | lua_newtable(L); // create arg table |
