Issue 494: fixed code to compile as well with Lua 5.1 and 5.2

git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1988 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
Yves Rizoud
2012-08-11 21:16:21 +00:00
parent a43c9eb31b
commit b1f6a0329b
2 changed files with 10 additions and 14 deletions

View File

@@ -1653,11 +1653,7 @@ void Run_script(const char *script_subdirectory, const char *script_filename)
Extract_path(buf,Last_run_script);
chdir(buf);
#if defined(__AROS__)
L = luaL_newstate(); // lua_open() doesn't exist anymore in Lua-5.2
#else
L = lua_open();
#endif
L = luaL_newstate(); // used to be lua_open() on Lua 5.1, deprecated on 5.2
strcpy(buf, "LUA_PATH=");
strcat(buf, Data_directory);