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/?p=lttng-tools.git;a=commitdiff_plain;h=7eac7803;hp=99611076d23e7fea0f639f6b46d71b6726da7d93 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)