diff options
Diffstat (limited to 'lbaselib.c')
-rw-r--r-- | lbaselib.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lbaselib.c,v 1.75 2002/05/16 19:09:19 roberto Exp roberto $ | 2 | ** $Id: lbaselib.c,v 1.76 2002/06/03 20:11:41 roberto Exp roberto $ |
3 | ** Basic library | 3 | ** Basic library |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -106,7 +106,7 @@ static int luaB_metatable (lua_State *L) { | |||
106 | 106 | ||
107 | static int luaB_globals (lua_State *L) { | 107 | static int luaB_globals (lua_State *L) { |
108 | lua_getglobals(L); /* value to be returned */ | 108 | lua_getglobals(L); /* value to be returned */ |
109 | if (!lua_isnone(L, 1)) { | 109 | if (!lua_isnoneornil(L, 1)) { |
110 | luaL_check_type(L, 1, LUA_TTABLE); | 110 | luaL_check_type(L, 1, LUA_TTABLE); |
111 | lua_pushvalue(L, 1); /* new table of globals */ | 111 | lua_pushvalue(L, 1); /* new table of globals */ |
112 | lua_setglobals(L); | 112 | lua_setglobals(L); |