From: Jonathan Rajotte Date: Mon, 13 Jan 2020 18:40:12 +0000 (-0500) Subject: Use lttng_trigger_is_equal when iterating over the trigger ht X-Git-Tag: v2.13.0-rc1~400 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=e8f7fa117487c9b57f5a9699364c3bebf53c5cec;hp=58daac01d91347336f24e1fc1cacd4e7a3101e93 Use lttng_trigger_is_equal when iterating over the trigger ht Since a trigger can now have other type of actions then the notify one, we must account for it. We use lttng_trigger_equal to perform that task. Signed-off-by: Jonathan Rajotte Signed-off-by: Jérémie Galarneau Change-Id: I3300b0fff66e760152c1f7065d8fbfb945cce48e --- diff --git a/src/bin/lttng-sessiond/notification-thread-events.c b/src/bin/lttng-sessiond/notification-thread-events.c index c318f833c..7ba78ba31 100644 --- a/src/bin/lttng-sessiond/notification-thread-events.c +++ b/src/bin/lttng-sessiond/notification-thread-events.c @@ -2598,13 +2598,7 @@ int handle_notification_thread_command_unregister_trigger( cds_list_for_each_entry_safe(trigger_element, tmp, &trigger_list->list, node) { - const struct lttng_condition *current_condition = - lttng_trigger_get_const_condition( - trigger_element->trigger); - - assert(current_condition); - if (!lttng_condition_is_equal(condition, - current_condition)) { + if (!lttng_trigger_is_equal(trigger, trigger_element->trigger)) { continue; }