cli: remove unused path variable in set_stream_intersections
authorSimon Marchi <simon.marchi@efficios.com>
Wed, 28 Aug 2019 20:41:54 +0000 (16:41 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Wed, 4 Sep 2019 15:58:22 +0000 (11:58 -0400)
The `path` variable is used in the error message, but never set, so it
will always appear as "(unknown)".

In the future, it would be nice if the error message gave more info to
the user.  But right now, it is pointless to keep `path` there, so
remove it.

Change-Id: If55d8246dde8cffe1b584477643f105acaaa4792
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1992
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Francis Deslauriers <francis.deslauriers@efficios.com>
src/cli/babeltrace2.c

index de0b6c2b7ef99c41e752fa4222c88c50bad00f83..0b6f2341b295d49b99b07ce091f750ad45846815 100644 (file)
@@ -1927,7 +1927,6 @@ int set_stream_intersections(struct cmd_run_ctx *ctx,
        int ret = 0;
        uint64_t trace_idx;
        int64_t trace_count;
-       const char *path = NULL;
        const bt_value *query_result = NULL;
        const bt_value *trace_info = NULL;
        const bt_value *intersection_range = NULL;
@@ -2098,8 +2097,7 @@ int set_stream_intersections(struct cmd_run_ctx *ctx,
 
 error:
        BT_CLI_LOGE_APPEND_CAUSE(
-               "Cannot determine stream intersection of trace: path=\"%s\"",
-               path ? path : "(unknown)");
+               "Cannot determine stream intersection of trace.");
 
 end:
        bt_value_put_ref(query_result);
This page took 0.027293 seconds and 4 git commands to generate.