summaryrefslogtreecommitdiff
path: root/lstrlib.c
diff options
context:
space:
mode:
Diffstat (limited to 'lstrlib.c')
-rw-r--r--lstrlib.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lstrlib.c b/lstrlib.c
index c380359b..0a0a6c13 100644
--- a/lstrlib.c
+++ b/lstrlib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lstrlib.c,v 1.46 2000/08/09 19:16:57 roberto Exp roberto $ 2** $Id: lstrlib.c,v 1.47 2000/08/28 17:57:04 roberto Exp roberto $
3** Standard library for string operations and pattern-matching 3** Standard library for string operations and pattern-matching
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -400,6 +400,7 @@ static const char *lmemfind (const char *s1, size_t l1,
400 400
401static int push_captures (lua_State *L, struct Capture *cap) { 401static int push_captures (lua_State *L, struct Capture *cap) {
402 int i; 402 int i;
403 luaL_checkstack(L, cap->level, "too many captures");
403 for (i=0; i<cap->level; i++) { 404 for (i=0; i<cap->level; i++) {
404 int l = cap->capture[i].len; 405 int l = cap->capture[i].len;
405 if (l == -1) lua_error(L, "unfinished capture"); 406 if (l == -1) lua_error(L, "unfinished capture");