aboutsummaryrefslogtreecommitdiff
path: root/loslib.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2011-11-29 13:55:51 -0200
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2011-11-29 13:55:51 -0200
commit61b1d9a4668286dcd43eb8771f4cdda4945d964e (patch)
treea6c266cb90e522d8db9bb0c78ee86c3b867797be /loslib.c
parent3617e04e972417144169d28184188a082eb40cbb (diff)
downloadlua-61b1d9a4668286dcd43eb8771f4cdda4945d964e.tar.gz
lua-61b1d9a4668286dcd43eb8771f4cdda4945d964e.tar.bz2
lua-61b1d9a4668286dcd43eb8771f4cdda4945d964e.zip
another try to avoid warnings about unreachable 'return' after 'exit'
Diffstat (limited to 'loslib.c')
-rw-r--r--loslib.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/loslib.c b/loslib.c
index bda2657d..c7ec4215 100644
--- a/loslib.c
+++ b/loslib.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: loslib.c,v 1.34 2011/03/03 16:34:46 roberto Exp roberto $ 2** $Id: loslib.c,v 1.35 2011/06/20 16:50:59 roberto Exp roberto $
3** Standard Operating System library 3** Standard Operating System library
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -274,7 +274,8 @@ static int os_exit (lua_State *L) {
274 status = luaL_optint(L, 1, EXIT_SUCCESS); 274 status = luaL_optint(L, 1, EXIT_SUCCESS);
275 if (lua_toboolean(L, 2)) 275 if (lua_toboolean(L, 2))
276 lua_close(L); 276 lua_close(L);
277 exit(status); 277 if (L) exit(status); /* 'if' to avoid warnings for unreachable 'return' */
278 return 0;
278} 279}
279 280
280 281