From: Simon Marchi Date: Thu, 2 May 2019 16:21:20 +0000 (-0400) Subject: src.ctf.fs: make trace-info query accept clock-class-offset-{s,ns} parameters X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=commitdiff_plain;h=d907165ce769b0eba30683cd5a4565242f8884c3;hp=d907165ce769b0eba30683cd5a4565242f8884c3 src.ctf.fs: make trace-info query accept clock-class-offset-{s,ns} parameters The src.ctf.fs components accept clock-class-offset-s and clock-class-offset-ns parameters, allowing to add an offset to the clock. The trace-info query currently doesn't accept the same parameters. In general, I think we'll want the components and trace-info to accept pretty much the same set of parameters, so that the information reported by trace-info accurately represents how an eventual component reading the same traces will work. This patch splits the parameter handling of the component in a standalone function re-used by the query. The advantage of sharing a function like this is that if we add a parameter to the component, we'll be forced to think about what happens to the trace-info query. One behavior change is that trace_info_query now returns BT_QUERY_STATUS_INVALID_PARAMS if the passed parameters are invalid. A test is added to test the new functionality. Change-Id: I3d917b8713fce4ce56a79a6e7c7bdc3e32d9ec0c Signed-off-by: Simon Marchi Reviewed-on: https://review.lttng.org/c/babeltrace/+/1244 Reviewed-by: Philippe Proulx ---