X-Git-Url: https://git.efficios.com/?a=blobdiff_plain;f=src%2Fplugins%2Fctf%2Ffs-src%2Fquery.cpp;h=a7225dda262f013fecb2aa24fdb6a591a759ba11;hb=c5a5a936663910e45158fe5f898ef5bb14c21624;hp=729dc5acaef4d793572ab0cd61dbe5293c366479;hpb=bf18373fe4ad13883fdffdfddce5b364a02a147c;p=babeltrace.git diff --git a/src/plugins/ctf/fs-src/query.cpp b/src/plugins/ctf/fs-src/query.cpp index 729dc5ac..a7225dda 100644 --- a/src/plugins/ctf/fs-src/query.cpp +++ b/src/plugins/ctf/fs-src/query.cpp @@ -168,14 +168,13 @@ static void populate_trace_info(const struct ctf_fs_trace *trace, const bt2::Map bt2::Value::Shared trace_infos_query(const bt2::ConstMapValue params, const bt2c::Logger& logger) { ctf_fs_component ctf_fs {logger}; - const bt_value *inputs_value = NULL; - const bt_value *trace_name_value; + const auto parameters = read_src_fs_parameters(params, logger); - if (!read_src_fs_parameters(params.libObjPtr(), &inputs_value, &trace_name_value, &ctf_fs)) { - BT_CPPLOGE_APPEND_CAUSE_AND_THROW_SPEC(logger, bt2::Error, "Failed to read parameters"); - } + ctf_fs.clkClsCfg = parameters.clkClsCfg; - if (ctf_fs_component_create_ctf_fs_trace(&ctf_fs, inputs_value, trace_name_value, NULL)) { + if (ctf_fs_component_create_ctf_fs_trace( + &ctf_fs, parameters.inputs, + parameters.traceName ? parameters.traceName->c_str() : nullptr, nullptr)) { BT_CPPLOGE_APPEND_CAUSE_AND_THROW_SPEC(logger, bt2::Error, "Failed to create trace"); }