summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2006-03-09 15:08:22 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2006-03-09 15:08:22 -0300
commit44a9bd6a8cb63adeb66537eacf56f45c91a318b6 (patch)
tree63371912f08abb36d8fc334d427369e7bd290167
parent69ea087dff1daba25a2000dfb8f1883c17545b7a (diff)
downloadlua-github-44a9bd6a8cb63adeb66537eacf56f45c91a318b6.tar.gz
detail
-rw-r--r--loslib.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/loslib.c b/loslib.c
index 760d84a2..26c1203a 100644
--- a/loslib.c
+++ b/loslib.c
@@ -1,5 +1,5 @@
/*
-** $Id: loslib.c,v 1.16 2005/12/22 16:19:56 roberto Exp roberto $
+** $Id: loslib.c,v 1.17 2006/01/27 13:54:31 roberto Exp roberto $
** Standard Operating System library
** See Copyright Notice in lua.h
*/
@@ -28,10 +28,7 @@ static int os_pushresult (lua_State *L, int i, const char *filename) {
}
else {
lua_pushnil(L);
- if (filename)
- lua_pushfstring(L, "%s: %s", filename, strerror(en));
- else
- lua_pushfstring(L, "%s", strerror(en));
+ lua_pushfstring(L, "%s: %s", filename, strerror(en));
lua_pushinteger(L, en);
return 3;
}