From: Jérémie Galarneau Date: Thu, 6 Oct 2016 18:52:19 +0000 (-0400) Subject: Fix: check for a session daemon before running load command X-Git-Tag: v2.8.2~2 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=78987a23bd3cf7353a34b04c0f894d7470f3274d;p=lttng-tools.git Fix: check for a session daemon before running load command Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng/commands/load.c b/src/bin/lttng/commands/load.c index d58cc07e0..64dc0fca6 100644 --- a/src/bin/lttng/commands/load.c +++ b/src/bin/lttng/commands/load.c @@ -150,6 +150,14 @@ int cmd_load(int argc, const char **argv) } } + ret = lttng_session_daemon_alive(); + if (!ret) { + ERR("No session daemon is available"); + ret = CMD_ERROR; + goto end; + } + ret = 0; + if (!opt_load_all) { session_name = poptGetArg(pc); if (session_name) {