X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fcmd.c;h=f8fa4dedddda209c3280b05e71f105d45a79a66d;hp=e1fbf769cbfb2833ecd98dc6b2f168e98f71dd4b;hb=141feb8ca12d48ef5adfcda81faa7e0d2fc32c7a;hpb=1adbdb1045a79cd4a02941c5994820ccb17a68c3 diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c index e1fbf769c..f8fa4dedd 100644 --- a/src/bin/lttng-sessiond/cmd.c +++ b/src/bin/lttng-sessiond/cmd.c @@ -1687,6 +1687,16 @@ static int _cmd_enable_event(struct ltt_session *session, assert(uchan); } + if (uchan->domain != LTTNG_DOMAIN_UST && !internal_event) { + /* + * Don't allow users to add UST events to channels which + * are assigned to a userspace subdomain (JUL, Log4J, + * Python, etc.). + */ + ret = LTTNG_ERR_INVALID_CHANNEL_DOMAIN; + goto error; + } + if (!internal_event) { /* * Ensure the event name is not reserved for internal