diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2002-08-06 12:32:22 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2002-08-06 12:32:22 -0300 |
commit | a2fa48a570b01b2a2cd37f01799f08f693fc5892 (patch) | |
tree | b41fc7e88f7f941ae1589921f8d7c0ff57146f4d /lauxlib.c | |
parent | 8b2b8790b5c419282f4fa0c7faa168379647b3b9 (diff) | |
download | lua-a2fa48a570b01b2a2cd37f01799f08f693fc5892.tar.gz lua-a2fa48a570b01b2a2cd37f01799f08f693fc5892.tar.bz2 lua-a2fa48a570b01b2a2cd37f01799f08f693fc5892.zip |
new (old?) error handling scheme
Diffstat (limited to 'lauxlib.c')
-rw-r--r-- | lauxlib.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lauxlib.c,v 1.78 2002/07/01 19:23:58 roberto Exp $ | 2 | ** $Id: lauxlib.c,v 1.79 2002/08/05 17:36:24 roberto Exp roberto $ |
3 | ** Auxiliary functions for building Lua libraries | 3 | ** Auxiliary functions for building Lua libraries |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -404,9 +404,7 @@ static void callalert (lua_State *L, int status) { | |||
404 | 404 | ||
405 | static int aux_do (lua_State *L, int status) { | 405 | static int aux_do (lua_State *L, int status) { |
406 | if (status == 0) { /* parse OK? */ | 406 | if (status == 0) { /* parse OK? */ |
407 | status = lua_pcall(L, 0, LUA_MULTRET); /* call main */ | 407 | status = lua_pcall(L, 0, LUA_MULTRET, 0); /* call main */ |
408 | if (status != 0) | ||
409 | lua_pcallreset(L); | ||
410 | } | 408 | } |
411 | callalert(L, status); | 409 | callalert(L, status); |
412 | return status; | 410 | return status; |