aboutsummaryrefslogtreecommitdiff
path: root/server.c
diff options
context:
space:
mode:
Diffstat (limited to 'server.c')
-rw-r--r--server.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/server.c b/server.c
index cd0cc70..4bc1ea8 100644
--- a/server.c
+++ b/server.c
@@ -471,7 +471,11 @@ main(int argc, char** argv)
client = authenticate(&clientsArena, clients_file, fds + conn, header);
if (!client)
+ {
loggingf("Could not initialize client (%d)\n", fds[conn].fd);
+ close(fds[conn].fd);
+ fds[conn].fd = -1;
+ }
/* This is the first time a message is sent, because unifd is not yet set. */
else if (!client->unifd)
{