From e869d17eb1309bfd81802a21b546a76e7ed6c38a Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 29 Jun 1998 15:24:06 -0300 Subject: functions should return explicit "nil"s. --- lstrlib.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lstrlib.c') diff --git a/lstrlib.c b/lstrlib.c index 72188723..613f6d53 100644 --- a/lstrlib.c +++ b/lstrlib.c @@ -1,5 +1,5 @@ /* -** $Id: lstrlib.c,v 1.15 1998/06/19 16:14:09 roberto Exp roberto $ +** $Id: lstrlib.c,v 1.16 1998/06/24 13:33:00 roberto Exp roberto $ ** Standard library for strings and pattern-matching ** See Copyright Notice in lua.h */ @@ -346,6 +346,7 @@ static void str_find (void) if (s2) { lua_pushnumber(s2-s+1); lua_pushnumber(s2-s+strlen(p)); + return; } } else { @@ -363,6 +364,7 @@ static void str_find (void) } } while (s1++