aboutsummaryrefslogtreecommitdiff
path: root/liolib.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2000-08-29 17:43:28 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2000-08-29 17:43:28 -0300
commita97f29f15487c5f584185f646f9cfc06a04b26ca (patch)
treee7ffd959fb80f9622d74a2efadfd7880037d64ca /liolib.c
parent4135f4f5862b57d9dbf3e9b7c6507f5c86516327 (diff)
downloadlua-a97f29f15487c5f584185f646f9cfc06a04b26ca.tar.gz
lua-a97f29f15487c5f584185f646f9cfc06a04b26ca.tar.bz2
lua-a97f29f15487c5f584185f646f9cfc06a04b26ca.zip
explicit stack control in the API
Diffstat (limited to 'liolib.c')
-rw-r--r--liolib.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/liolib.c b/liolib.c
index 4c0cbf2b..0a310de0 100644
--- a/liolib.c
+++ b/liolib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: liolib.c,v 1.72 2000/08/28 17:57:04 roberto Exp roberto $ 2** $Id: liolib.c,v 1.73 2000/08/29 14:33:31 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*/
@@ -372,6 +372,7 @@ static int io_read (lua_State *L) {
372 firstarg = lastarg = 1; /* correct indices */ 372 firstarg = lastarg = 1; /* correct indices */
373 lua_pushstring(L, "*l"); /* push default argument */ 373 lua_pushstring(L, "*l"); /* push default argument */
374 } 374 }
375 luaL_checkstack(L, lastarg-firstarg+1, "too many results");
375 for (n = firstarg; n<=lastarg; n++) { 376 for (n = firstarg; n<=lastarg; n++) {
376 size_t l; 377 size_t l;
377 int success; 378 int success;