Clean-up: ust-app: use const condition and event rule
authorJonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Wed, 24 Feb 2021 19:24:09 +0000 (14:24 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Wed, 8 May 2024 19:52:04 +0000 (19:52 +0000)
At this point only const object are required.

Signed-off-by: Jonathan Rajotte <jonathan.rajotte-julien@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: I9c297fdd6e8026db4e0dc56bd9238fec05fbae3b

src/bin/lttng-sessiond/ust-app.cpp

index 12250edfdaefb1341736ba5b78c62a53ceba1c8e..d993b7b4439059f2448940f7b3130a2e638e3954 100644 (file)
@@ -6025,8 +6025,8 @@ static void ust_app_synchronize_event_notifier_rules(struct ust_app *app)
        }
 
        for (i = 0; i < count; i++) {
-               struct lttng_condition *condition;
-               struct lttng_event_rule *event_rule;
+               const struct lttng_condition *condition;
+               const struct lttng_event_rule *event_rule;
                struct lttng_trigger *trigger;
                const struct ust_app_event_notifier_rule *looked_up_event_notifier_rule;
                enum lttng_condition_status condition_status;
@@ -6036,7 +6036,7 @@ static void ust_app_synchronize_event_notifier_rules(struct ust_app *app)
                LTTNG_ASSERT(trigger);
 
                token = lttng_trigger_get_tracer_token(trigger);
-               condition = lttng_trigger_get_condition(trigger);
+               condition = lttng_trigger_get_const_condition(trigger);
 
                if (lttng_condition_get_type(condition) !=
                    LTTNG_CONDITION_TYPE_EVENT_RULE_MATCHES) {
@@ -6044,8 +6044,8 @@ static void ust_app_synchronize_event_notifier_rules(struct ust_app *app)
                        continue;
                }
 
-               condition_status = lttng_condition_event_rule_matches_borrow_rule_mutable(
-                       condition, &event_rule);
+               condition_status =
+                       lttng_condition_event_rule_matches_get_rule(condition, &event_rule);
                LTTNG_ASSERT(condition_status == LTTNG_CONDITION_STATUS_OK);
 
                if (lttng_event_rule_get_domain_type(event_rule) == LTTNG_DOMAIN_KERNEL) {
This page took 0.028794 seconds and 4 git commands to generate.