aboutsummaryrefslogtreecommitdiff
path: root/ldo.c
diff options
context:
space:
mode:
Diffstat (limited to 'ldo.c')
-rw-r--r--ldo.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/ldo.c b/ldo.c
index 2bbfdd5f..c8797a7c 100644
--- a/ldo.c
+++ b/ldo.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ldo.c,v 1.49 1999/10/14 17:53:35 roberto Exp roberto $ 2** $Id: ldo.c,v 1.50 1999/10/14 19:46:57 roberto Exp roberto $
3** Stack and Call structure of Lua 3** Stack and Call structure of Lua
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -219,7 +219,7 @@ void luaD_calln (int nArgs, int nResults) {
219 219
220 220
221static void message (const char *s) { 221static void message (const char *s) {
222 const TObject *em = &(luaS_new("_ERRORMESSAGE")->u.s.globalval); 222 const TObject *em = &(luaS_assertglobalbyname("_ERRORMESSAGE")->value);
223 if (ttype(em) == LUA_T_PROTO || ttype(em) == LUA_T_CPROTO || 223 if (ttype(em) == LUA_T_PROTO || ttype(em) == LUA_T_CPROTO ||
224 ttype(em) == LUA_T_CLOSURE) { 224 ttype(em) == LUA_T_CLOSURE) {
225 *L->stack.top = *em; 225 *L->stack.top = *em;
@@ -237,7 +237,6 @@ void lua_error (const char *s) {
237 if (L->errorJmp) 237 if (L->errorJmp)
238 longjmp(L->errorJmp->b, 1); 238 longjmp(L->errorJmp->b, 1);
239 else { 239 else {
240 LUA_INTERNALERROR("exit!!");
241 message("exit(1). Unable to recover.\n"); 240 message("exit(1). Unable to recover.\n");
242 exit(1); 241 exit(1);
243 } 242 }