From 3fdffb558a87e75e644f2c8d86c226c291ee25b6 Mon Sep 17 00:00:00 2001 From: Philippe Proulx Date: Thu, 4 Jul 2019 01:51:33 -0400 Subject: [PATCH] src.ctf.fs: append error cause when no traces are found in directory This is just to have at least one way to test the CLI error reporting with a component actor. Signed-off-by: Philippe Proulx Change-Id: Iaf59163123c48944168e4e6d0ad1c87ea51cdc5a Reviewed-on: https://review.lttng.org/c/babeltrace/+/1619 Tested-by: jenkins Reviewed-by: Francis Deslauriers Reviewed-by: Simon Marchi --- src/plugins/ctf/fs-src/fs.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/plugins/ctf/fs-src/fs.c b/src/plugins/ctf/fs-src/fs.c index b9faf97a..84dae6a1 100644 --- a/src/plugins/ctf/fs-src/fs.c +++ b/src/plugins/ctf/fs-src/fs.c @@ -1315,6 +1315,9 @@ int ctf_fs_component_create_ctf_fs_traces_one_root( if (!trace_paths) { BT_COMP_LOGE("No CTF traces recursively found in `%s`.", path_param); + (void) BT_CURRENT_THREAD_ERROR_APPEND_CAUSE_FROM_COMPONENT( + ctf_fs->self_comp, + "No CTF traces recursively found in `%s`.", path_param); goto error; } -- 2.34.1