X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fclient.c;h=09e683a712d8b41914f9938d306b65b506c74635;hb=9b7cbebd7d78c0950c84cd834ce15d3298d997e6;hp=e1552c345659184d7c3973393a656c520a7f85e5;hpb=37f3c202d364b9a78c37db821c508ef3a6b1f711;p=lttng-tools.git diff --git a/src/bin/lttng-sessiond/client.c b/src/bin/lttng-sessiond/client.c index e1552c345..09e683a71 100644 --- a/src/bin/lttng-sessiond/client.c +++ b/src/bin/lttng-sessiond/client.c @@ -43,6 +43,7 @@ #include "utils.h" #include "manage-consumer.h" #include "clear.h" +#include "agent-thread.h" static bool is_root; @@ -844,7 +845,9 @@ static int process_client_msg(struct command_ctx *cmd_ctx, int *sock, bool need_domain; bool need_consumerd; - DBG("Processing client command %d", cmd_ctx->lsm.cmd_type); + DBG("Processing client command '%s\' (%d)", + lttcomm_sessiond_command_str(cmd_ctx->lsm.cmd_type), + cmd_ctx->lsm.cmd_type); assert(!rcu_read_ongoing()); @@ -1076,6 +1079,11 @@ static int process_client_msg(struct command_ctx *cmd_ctx, int *sock, case LTTNG_DOMAIN_JUL: case LTTNG_DOMAIN_LOG4J: case LTTNG_DOMAIN_PYTHON: + if (!agent_tracing_is_enabled()) { + ret = LTTNG_ERR_AGENT_TRACING_DISABLED; + goto error; + } + /* Fallthrough */ case LTTNG_DOMAIN_UST: { if (!ust_app_supported()) {