From: Jérémie Galarneau Date: Mon, 23 Apr 2018 20:36:25 +0000 (-0400) Subject: Fix: agent may not be ready on launch X-Git-Tag: v2.9.9~3 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=b86685ef513314b56785e3d6c457e321dc8a9d1c;p=lttng-tools.git Fix: agent may not be ready on launch Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/agent-thread.c b/src/bin/lttng-sessiond/agent-thread.c index 39d2ec4a0..4d53d6e09 100644 --- a/src/bin/lttng-sessiond/agent-thread.c +++ b/src/bin/lttng-sessiond/agent-thread.c @@ -248,6 +248,7 @@ void *agent_thread_manage_registration(void *data) } reg_sock = init_tcp_socket(); + sessiond_notify_ready(); if (!reg_sock) { goto error_tcp_socket; } diff --git a/src/bin/lttng-sessiond/main.c b/src/bin/lttng-sessiond/main.c index 3c2d2a756..b4d82f3bf 100644 --- a/src/bin/lttng-sessiond/main.c +++ b/src/bin/lttng-sessiond/main.c @@ -313,7 +313,7 @@ struct lttng_ht *agent_apps_ht_by_sock = NULL; * NR_LTTNG_SESSIOND_READY must match the number of calls to * sessiond_notify_ready(). */ -#define NR_LTTNG_SESSIOND_READY 3 +#define NR_LTTNG_SESSIOND_READY 4 int lttng_sessiond_ready = NR_LTTNG_SESSIOND_READY; int sessiond_check_thread_quit_pipe(int fd, uint32_t events)