summaryrefslogtreecommitdiffstats
path: root/xup/xup.c
diff options
context:
space:
mode:
Diffstat (limited to 'xup/xup.c')
-rw-r--r--xup/xup.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/xup/xup.c b/xup/xup.c
index 294500be..4964692a 100644
--- a/xup/xup.c
+++ b/xup/xup.c
@@ -212,10 +212,15 @@ lib_mod_connect(struct mod *mod)
if (use_uds)
{
mod->sck = g_tcp_local_socket();
+ if (mod->sck < 0)
+ return 1;
}
else
{
mod->sck = g_tcp_socket();
+ if (mod->sck < 0)
+ return 1;
+
g_tcp_set_non_blocking(mod->sck);
g_tcp_set_no_delay(mod->sck);
}