From 37b49aa4516934fcb23bbdb62a82ab1916275ac8 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Thu, 6 Oct 2005 17:44:22 -0300 Subject: detail --- ldo.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'ldo.c') diff --git a/ldo.c b/ldo.c index c0a1824f..36e8af18 100644 --- a/ldo.c +++ b/ldo.c @@ -1,5 +1,5 @@ /* -** $Id: ldo.c,v 2.32 2005/08/24 16:15:49 roberto Exp roberto $ +** $Id: ldo.c,v 2.33 2005/09/09 18:16:28 roberto Exp roberto $ ** Stack and Call structure of Lua ** See Copyright Notice in lua.h */ @@ -316,14 +316,12 @@ int luaD_precall (lua_State *L, StkId func, int nresults) { lua_unlock(L); n = (*curr_func(L)->c.f)(L); /* do the actual call */ lua_lock(L); - if (n >= 0) { /* no yielding? */ + if (n < 0) /* yielding? */ + return PCRYIELD; + else { luaD_poscall(L, L->top - n); return PCRC; } - else { - ci->nresults = nresults; - return PCRYIELD; - } } } -- cgit v1.2.3-55-g6feb