[lttng-dev] [PATCH lttng-tools 2/3] Fix: disable all ust events
Jérémie Galarneau
jeremie.galarneau at efficios.com
Wed Sep 16 16:32:03 EDT 2015
On Thu, Sep 10, 2015 at 4:10 PM, Jonathan Rajotte
<jonathan.rajotte-julien at efficios.com> wrote:
> Handle * event correctly.
>
> Fixes #936
>
> Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien at efficios.com>
> ---
> src/bin/lttng-sessiond/cmd.c | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c
> index 058dbae..470f29d 100644
> --- a/src/bin/lttng-sessiond/cmd.c
> +++ b/src/bin/lttng-sessiond/cmd.c
> @@ -1290,7 +1290,11 @@ int cmd_disable_event(struct ltt_session *session,
>
> switch (event->type) {
> case LTTNG_EVENT_ALL:
> - ret = event_ust_disable_tracepoint(usess, uchan, event_name);
> + if (strncmp(event->name, "*", 1) == 0 && strlen(event->name) == 1) {
> + ret = event_ust_disable_all_tracepoints(usess, uchan);
> + } else {
> + ret = event_ust_disable_tracepoint(usess, uchan, event_name);
> + }
Merged with adjustments to fit within 80 columns.
Thanks!
Jérémie
> if (ret != LTTNG_OK) {
> goto error_unlock;
> }
> --
> 2.1.4
>
--
Jérémie Galarneau
EfficiOS Inc.
http://www.efficios.com
More information about the lttng-dev
mailing list