sessiond: index_ht_entry: use lttng::utils::container_of
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Mon, 22 Jul 2024 19:13:11 +0000 (19:13 +0000)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 30 Jul 2024 01:26:51 +0000 (01:26 +0000)
caa_container_of makes use of offsetof which is conditionally
supported for non-POD types. Replace its use by
lttng::utils::container_of.

Change-Id: Ic2ed13700b8258b274aef9153ebc9d2a6a3536f3
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/event-notifier-error-accounting.cpp

index 27d049601c1bc24662f9d9c68f08abe7fdf279a3..9672fdc6bde6619c0f2b756490e0e040e1aef4b2 100644 (file)
@@ -1248,7 +1248,7 @@ event_notifier_error_accounting_clear(const struct lttng_trigger *trigger)
 
 static void free_index_ht_entry(struct rcu_head *head)
 {
-       struct index_ht_entry *entry = caa_container_of(head, struct index_ht_entry, rcu_head);
+       auto *entry = lttng::utils::container_of(head, &index_ht_entry::rcu_head);
 
        free(entry);
 }
This page took 0.024906 seconds and 4 git commands to generate.