From c203f0585aa3a3b1c2b1994899b8277ed79dad2d Mon Sep 17 00:00:00 2001 From: Jonathan Rajotte Date: Wed, 23 Sep 2020 16:13:37 -0400 Subject: [PATCH] action-executor: evaluated object credentials are optional MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Use the is_set member instead of the LTTNG_OPTIONAL_GET_PTR macro which asserts whenever an optional member is unset. Signed-off-by: Jonathan Rajotte Signed-off-by: Jérémie Galarneau Change-Id: Ia00e4a7f5f9b8198061a742bf6bd750c721908cf --- src/bin/lttng-sessiond/action-executor.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/bin/lttng-sessiond/action-executor.c b/src/bin/lttng-sessiond/action-executor.c index 4f027fdb9..5459c4b5e 100644 --- a/src/bin/lttng-sessiond/action-executor.c +++ b/src/bin/lttng-sessiond/action-executor.c @@ -198,7 +198,9 @@ static int action_executor_notify_handler(struct action_executor *executor, lttng_trigger_get_const_condition(work_item->trigger), work_item->evaluation, lttng_trigger_get_credentials(work_item->trigger), - LTTNG_OPTIONAL_GET_PTR(work_item->object_creds), + work_item->object_creds.is_set ? + &(work_item->object_creds.value) : + NULL, client_handle_transmission_status, executor); } -- 2.34.1