From 798660c9cddef8a73f68058576e3d47eed2b1a27 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Wed, 1 Oct 2014 08:54:56 -0300 Subject: deprecated "cast macros" ('luaL_checkint', 'luaL_optint', etc.) --- loslib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'loslib.c') diff --git a/loslib.c b/loslib.c index c55a6526..209e74cd 100644 --- a/loslib.c +++ b/loslib.c @@ -1,5 +1,5 @@ /* -** $Id: loslib.c,v 1.45 2014/03/20 19:18:54 roberto Exp roberto $ +** $Id: loslib.c,v 1.46 2014/04/29 17:05:13 roberto Exp roberto $ ** Standard Operating System library ** See Copyright Notice in lua.h */ @@ -319,7 +319,7 @@ static int os_exit (lua_State *L) { if (lua_isboolean(L, 1)) status = (lua_toboolean(L, 1) ? EXIT_SUCCESS : EXIT_FAILURE); else - status = luaL_optint(L, 1, EXIT_SUCCESS); + status = (int)luaL_optinteger(L, 1, EXIT_SUCCESS); if (lua_toboolean(L, 2)) lua_close(L); if (L) exit(status); /* 'if' to avoid warnings for unreachable 'return' */ -- cgit v1.2.3-55-g6feb