summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xC.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/xC.c b/xC.c
index d65e85a..e35cfc6 100644
--- a/xC.c
+++ b/xC.c
@@ -2868,6 +2868,7 @@ relay_try_fetch_client (struct app_context *ctx, int listen_fd)
if (accept_error_is_transient (errno))
print_warning ("%s: %s", "accept", strerror (errno));
else
+ // TODO: Rather dispose of the listening socket.
print_fatal ("%s: %s", "accept", strerror (errno));
return true;
}
@@ -14760,7 +14761,8 @@ try_reap_child (struct app_context *ctx)
if (WIFSTOPPED (status))
{
// We could also send SIGCONT but what's the point
- print_debug ("a child has been stopped, killing its process group");
+ log_global_debug (ctx,
+ "A child has been stopped, killing its process group");
kill (-zombie, SIGKILL);
return true;
}
@@ -15258,7 +15260,7 @@ client_process_message (struct client *c,
if (!relay_command_message_deserialize (m, r)
|| msg_unpacker_get_available (r))
{
- print_error ("deserialization failed, killing client");
+ log_global_error (c->ctx, "Deserialization failed, killing client");
return false;
}
@@ -15277,7 +15279,8 @@ client_process_message (struct client *c,
if (m->data.hello.version != RELAY_VERSION)
{
// TODO: This should send back an error message and shut down.
- print_error ("protocol version mismatch, killing client");
+ log_global_error (c->ctx,
+ "Protocol version mismatch, killing client");
return false;
}
c->initialized = true;
@@ -15305,7 +15308,7 @@ client_process_message (struct client *c,
client_process_buffer_log (c, m->command_seq, buffer);
break;
default:
- print_warning ("unhandled client command");
+ log_global_debug (c->ctx, "Unhandled client command");
relay_prepare_error (c->ctx, m->command_seq, "Unknown command");
relay_send (c);
}