aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2010-08-31 15:23:41 +0100
committerMatthew Wild <mwild1@gmail.com>2010-08-31 15:23:41 +0100
commitc739eebe35537fb0d420627d50bcd68c53a0a6f0 (patch)
tree26b953b24b8d2562fb09acadcc381f60b9f9af4a
parent50b20f4af49bda557b78da9f7d3cb6b1f620e7e8 (diff)
downloadprosody-c739eebe35537fb0d420627d50bcd68c53a0a6f0.tar.gz
prosody-c739eebe35537fb0d420627d50bcd68c53a0a6f0.zip
util.pposix: uname(): Fix to push nil,err in case of error
-rw-r--r--util-src/pposix.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/util-src/pposix.c b/util-src/pposix.c
index c5ebc4b4..4ff84bde 100644
--- a/util-src/pposix.c
+++ b/util-src/pposix.c
@@ -559,6 +559,7 @@ int lc_uname(lua_State* L)
struct utsname uname_info;
if(uname(&uname_info) != 0)
{
+ lua_pushnil(L);
lua_pushstring(L, strerror(errno));
return 2;
}