diff options
| -rw-r--r-- | opcode.c | 6 |
1 files changed, 4 insertions, 2 deletions
| @@ -3,7 +3,7 @@ | |||
| 3 | ** TecCGraf - PUC-Rio | 3 | ** TecCGraf - PUC-Rio |
| 4 | */ | 4 | */ |
| 5 | 5 | ||
| 6 | char *rcs_opcode="$Id: opcode.c,v 3.33 1995/02/02 20:05:37 roberto Exp roberto $"; | 6 | char *rcs_opcode="$Id: opcode.c,v 3.34 1995/02/06 19:35:09 roberto Exp roberto $"; |
| 7 | 7 | ||
| 8 | #include <setjmp.h> | 8 | #include <setjmp.h> |
| 9 | #include <stdlib.h> | 9 | #include <stdlib.h> |
| @@ -184,7 +184,9 @@ static int lua_tostring (Object *obj) | |||
| 184 | */ | 184 | */ |
| 185 | static void adjust_top (StkId newtop) | 185 | static void adjust_top (StkId newtop) |
| 186 | { | 186 | { |
| 187 | Object *nt = stack+newtop; | 187 | Object *nt; |
| 188 | lua_checkstack(newtop); | ||
| 189 | nt = stack+newtop; | ||
| 188 | while (top < nt) tag(top++) = LUA_T_NIL; | 190 | while (top < nt) tag(top++) = LUA_T_NIL; |
| 189 | top = nt; /* top could be bigger than newtop */ | 191 | top = nt; /* top could be bigger than newtop */ |
| 190 | } | 192 | } |
