aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/mds-server.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/src/mds-server.c b/src/mds-server.c
index 9512457..a82c5e0 100644
--- a/src/mds-server.c
+++ b/src/mds-server.c
@@ -353,15 +353,24 @@ void* slave_loop(void* data)
fprintf(stderr, "%s: corrupt message received.\n", *argv);
goto fail;
}
- else if (errno != EINTR)
+ else if (errno == ECONNRESET)
{
- perror(*argv);
- goto fail;
+ r = mds_message_read(&(information->message), socket_fd);
+ if (r == 0)
+ {
+ /* TODO */
+ }
+ break; /* Connection closed. */
}
- else
+ else if (errno == EINTR)
{
/* TODO */
}
+ else
+ {
+ perror(*argv);
+ goto fail;
+ }
}