summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--libs/nixio/src/bind.c2
-rw-r--r--libs/nixio/src/nixio.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/libs/nixio/src/bind.c b/libs/nixio/src/bind.c
index 81ab0bb48..711205955 100644
--- a/libs/nixio/src/bind.c
+++ b/libs/nixio/src/bind.c
@@ -180,7 +180,7 @@ static int nixio_sock__bind_connect(lua_State *L, int do_bind) {
}
/* on success */
- if (!status) {
+ if (!status || errno == EINPROGRESS) {
break;
}
}
diff --git a/libs/nixio/src/nixio.c b/libs/nixio/src/nixio.c
index f6e8e184c..70a77b4c9 100644
--- a/libs/nixio/src/nixio.c
+++ b/libs/nixio/src/nixio.c
@@ -198,6 +198,8 @@ NIXIO_API int luaopen_nixio(lua_State *L) {
NIXIO_PUSH_CONSTANT(SIGSEGV);
#ifndef __WINNT__
+ NIXIO_PUSH_CONSTANT(EALREADY);
+ NIXIO_PUSH_CONSTANT(EINPROGRESS);
NIXIO_PUSH_CONSTANT(EWOULDBLOCK);
NIXIO_PUSH_CONSTANT(ELOOP);
NIXIO_PUSH_CONSTANT(EOVERFLOW);