From af6bce8078af432ec0bb59db4f33095c26845c4d Mon Sep 17 00:00:00 2001 From: David Goulet Date: Thu, 27 Feb 2014 15:04:53 -0500 Subject: [PATCH] Fix: handle loglevel range ALL in list command Print the ":" if we get the ALL range and not TYPE UNKNOWN. Signed-off-by: David Goulet --- src/bin/lttng/commands/list.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/bin/lttng/commands/list.c b/src/bin/lttng/commands/list.c index 1a46bb72b..f69b3ba3d 100644 --- a/src/bin/lttng/commands/list.c +++ b/src/bin/lttng/commands/list.c @@ -220,12 +220,14 @@ 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 "<="; + return " <="; case LTTNG_EVENT_LOGLEVEL_SINGLE: - return "=="; + return " =="; default: - return "<>"; + return " <>"; } } @@ -238,7 +240,7 @@ static void print_events(struct lttng_event *event) case LTTNG_EVENT_TRACEPOINT: { if (event->loglevel != -1) { - MSG("%s%s (loglevel %s %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), -- 2.34.1