diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2009-06-04 16:34:24 -0300 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2009-06-04 16:34:24 -0300 |
| commit | 5cdec7d124e46c1409df8033f1b795a996dd00e4 (patch) | |
| tree | 933b944304b7919f7087c4701a907441f29a33a8 | |
| parent | 9423e22aa35f47b392fc52a1b93c1be4c69f2aee (diff) | |
| download | lua-5cdec7d124e46c1409df8033f1b795a996dd00e4.tar.gz lua-5cdec7d124e46c1409df8033f1b795a996dd00e4.tar.bz2 lua-5cdec7d124e46c1409df8033f1b795a996dd00e4.zip | |
added "\n" at the end of 'package.config' (so that the string
is a sequence of complete lines)
| -rw-r--r-- | loadlib.c | 4 |
1 files changed, 2 insertions, 2 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: loadlib.c,v 1.61 2008/08/06 13:38:32 roberto Exp roberto $ | 2 | ** $Id: loadlib.c,v 1.62 2009/03/26 22:25:05 roberto Exp roberto $ |
| 3 | ** Dynamic library loader for Lua | 3 | ** Dynamic library loader for Lua |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | ** | 5 | ** |
| @@ -669,7 +669,7 @@ LUALIB_API int luaopen_package (lua_State *L) { | |||
| 669 | setpath(L, "cpath", LUA_CPATH, LUA_CPATH_DEFAULT); /* set field `cpath' */ | 669 | setpath(L, "cpath", LUA_CPATH, LUA_CPATH_DEFAULT); /* set field `cpath' */ |
| 670 | /* store config information */ | 670 | /* store config information */ |
| 671 | lua_pushliteral(L, LUA_DIRSEP "\n" LUA_PATHSEP "\n" LUA_PATH_MARK "\n" | 671 | lua_pushliteral(L, LUA_DIRSEP "\n" LUA_PATHSEP "\n" LUA_PATH_MARK "\n" |
| 672 | LUA_EXECDIR "\n" LUA_IGMARK); | 672 | LUA_EXECDIR "\n" LUA_IGMARK "\n"); |
| 673 | lua_setfield(L, -2, "config"); | 673 | lua_setfield(L, -2, "config"); |
| 674 | /* set field `loaded' */ | 674 | /* set field `loaded' */ |
| 675 | luaL_findtable(L, LUA_REGISTRYINDEX, "_LOADED", 2); | 675 | luaL_findtable(L, LUA_REGISTRYINDEX, "_LOADED", 2); |
