Fix: lib: fix memory leak in simple_sink_init error path
If bt_self_component_sink_add_input_port fails, we don't free the
simple_sink_data instance.
Move the code to free a simple_sink_data in a new function,
simple_sink_data_destroy. Call it from simple_sink_finalize and from
simple_sink_init's error path.
Change-Id: If8f87ef4a39836e02ed1c125dc8feb160d21cc37
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/7196
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
Tested-by: jenkins <jenkins@lttng.org>
This page took 0.024763 seconds and 4 git commands to generate.