From: Jonathan Rajotte Julien Date: Thu, 3 Jul 2014 13:57:11 +0000 (-0400) Subject: Fix mi: use of wrong variable for error propagation X-Git-Tag: v2.6.0-rc1~112 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=da3d7d0e160ca3c7d78002a8e7ba9ee66e42a540;p=lttng-tools.git Fix mi: use of wrong variable for error propagation Signed-off-by: Jonathan Rajotte Julien --- diff --git a/src/bin/lttng/commands/enable_events.c b/src/bin/lttng/commands/enable_events.c index 1f4e02470..46a08d88c 100644 --- a/src/bin/lttng/commands/enable_events.c +++ b/src/bin/lttng/commands/enable_events.c @@ -761,8 +761,8 @@ static int enable_events(char *session_name) break; default: ERR("All events: %s (channel %s, session %s, filter \'%s\')", - lttng_strerror(ret), - ret == -LTTNG_ERR_NEED_CHANNEL_NAME + lttng_strerror(command_ret), + command_ret == -LTTNG_ERR_NEED_CHANNEL_NAME ? print_raw_channel_name(channel_name) : print_channel_name(channel_name), session_name, opt_filter); @@ -989,8 +989,8 @@ static int enable_events(char *session_name) default: ERR("Event %s%s: %s (channel %s, session %s)", event_name, exclusion_string, - lttng_strerror(ret), - ret == -LTTNG_ERR_NEED_CHANNEL_NAME + lttng_strerror(command_ret), + command_ret == -LTTNG_ERR_NEED_CHANNEL_NAME ? print_raw_channel_name(channel_name) : print_channel_name(channel_name), session_name); @@ -1037,8 +1037,8 @@ static int enable_events(char *session_name) default: ERR("Event %s%s: %s (channel %s, session %s, filter \'%s\')", ev.name, exclusion_string, - lttng_strerror(ret), - ret == -LTTNG_ERR_NEED_CHANNEL_NAME + lttng_strerror(command_ret), + command_ret == -LTTNG_ERR_NEED_CHANNEL_NAME ? print_raw_channel_name(channel_name) : print_channel_name(channel_name), session_name, opt_filter);