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.11.0-rc1~268 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=7eac78030ec056b149f110d156b855b1e7d2c00f;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 3a46c0fb9..ddc6c7e62 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 e0195a5db..0620c7e70 100644 --- a/src/bin/lttng-sessiond/main.c +++ b/src/bin/lttng-sessiond/main.c @@ -304,7 +304,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 5 +#define NR_LTTNG_SESSIOND_READY 6 int lttng_sessiond_ready = NR_LTTNG_SESSIOND_READY; int sessiond_check_thread_quit_pipe(int fd, uint32_t events)