aboutsummaryrefslogtreecommitdiffstats
path: root/util-src/poll.c
diff options
context:
space:
mode:
Diffstat (limited to 'util-src/poll.c')
-rw-r--r--util-src/poll.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/util-src/poll.c b/util-src/poll.c
index 7fd28524..58f29041 100644
--- a/util-src/poll.c
+++ b/util-src/poll.c
@@ -452,10 +452,16 @@ int luaopen_util_poll(lua_State *L) {
#endif
}
- lua_createtable(L, 0, 1);
+ lua_createtable(L, 0, 2);
{
lua_pushcfunction(L, Lnew);
lua_setfield(L, -2, "new");
+
+#define push_errno(named_error) lua_pushinteger(L, named_error);\
+ lua_setfield(L, -2, #named_error);
+
+ push_errno(EEXIST);
+
}
return 1;
}