From: David Goulet Date: Thu, 27 Feb 2014 20:04:53 +0000 (-0500) Subject: Fix: handle loglevel range ALL in list command X-Git-Tag: v2.5.0-rc1~138 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=af6bce8078af432ec0bb59db4f33095c26845c4d;p=lttng-tools.git 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 --- 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),