X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fbin%2Flttng%2Fcommands%2Flist.c;h=f69b3ba3d67b1b8ce5a2b02b839d032f306f4a0e;hb=1114378362fe014288ccaab1d1fed52f7b5703f8;hp=66a322a06adb650b2a593c9147a7d9ed556bf8ba;hpb=1c3de747c6d5262ca06a9ff849385fa16751a84d;p=lttng-tools.git diff --git a/src/bin/lttng/commands/list.c b/src/bin/lttng/commands/list.c index 66a322a06..f69b3ba3d 100644 --- a/src/bin/lttng/commands/list.c +++ b/src/bin/lttng/commands/list.c @@ -217,6 +217,20 @@ static const char *loglevel_string(int value) } } +static const char *logleveltype_string(enum lttng_loglevel_type value) +{ + switch (value) { + case LTTNG_EVENT_LOGLEVEL_ALL: + return ":"; + case LTTNG_EVENT_LOGLEVEL_RANGE: + return " <="; + case LTTNG_EVENT_LOGLEVEL_SINGLE: + return " =="; + default: + return " <>"; + } +} + /* * Pretty print single event. */ @@ -226,9 +240,10 @@ static void print_events(struct lttng_event *event) case LTTNG_EVENT_TRACEPOINT: { if (event->loglevel != -1) { - MSG("%s%s (loglevel: %s (%d)) (type: tracepoint)%s%s%s", + MSG("%s%s (loglevel%s %s (%d)) (type: tracepoint)%s%s%s", indent6, event->name, + logleveltype_string(event->loglevel_type), loglevel_string(event->loglevel), event->loglevel, enabled_string(event->enabled),