diff options
Diffstat (limited to 'liolib.c')
| -rw-r--r-- | liolib.c | 6 |
1 files changed, 3 insertions, 3 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: liolib.c,v 1.68 2000/06/20 17:13:21 roberto Exp roberto $ | 2 | ** $Id: liolib.c,v 1.69 2000/08/09 19:16:57 roberto Exp roberto $ |
| 3 | ** Standard I/O (and system) library | 3 | ** Standard I/O (and system) library |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -73,7 +73,7 @@ static void atribTM (lua_State *L) { | |||
| 73 | ctrl->file[inout] = (FILE *)lua_getuserdata(L, newvalue); | 73 | ctrl->file[inout] = (FILE *)lua_getuserdata(L, newvalue); |
| 74 | } | 74 | } |
| 75 | /* set the actual variable */ | 75 | /* set the actual variable */ |
| 76 | lua_pushglobaltable(L); | 76 | lua_pushglobals(L); |
| 77 | lua_pushstring(L, varname); | 77 | lua_pushstring(L, varname); |
| 78 | lua_pushobject(L, newvalue); | 78 | lua_pushobject(L, newvalue); |
| 79 | lua_rawset(L); | 79 | lua_rawset(L); |
| @@ -590,7 +590,7 @@ static void errorfb (lua_State *L) { | |||
| 590 | sprintf(buff+strlen(buff), " [%.70s]", buffchunk); | 590 | sprintf(buff+strlen(buff), " [%.70s]", buffchunk); |
| 591 | strcat(buff, "\n"); | 591 | strcat(buff, "\n"); |
| 592 | } | 592 | } |
| 593 | lua_pushglobaltable(L); | 593 | lua_pushglobals(L); |
| 594 | lua_pushstring(L, LUA_ALERT); | 594 | lua_pushstring(L, LUA_ALERT); |
| 595 | alertfunc = lua_rawget(L); | 595 | alertfunc = lua_rawget(L); |
| 596 | if (lua_isfunction(L, alertfunc)) { /* avoid loop if _ALERT is not defined */ | 596 | if (lua_isfunction(L, alertfunc)) { /* avoid loop if _ALERT is not defined */ |
