Fix: sessiond: size-based rotation threshold exceeded in per-pid tracing (2/2)
[lttng-tools.git] / src / common / consumer / consumer-stream.cpp
index c22c7e5f3390f74576bb22fa0bfe10e506ed9a51..bb0ec0a2436db1a9fb042b29b1e53b622c2eb60e 100644 (file)
@@ -35,9 +35,9 @@
 static void free_stream_rcu(struct rcu_head *head)
 {
        struct lttng_ht_node_u64 *node =
-               caa_container_of(head, struct lttng_ht_node_u64, head);
+               lttng::utils::container_of(head, &lttng_ht_node_u64::head);
        struct lttng_consumer_stream *stream =
-               caa_container_of(node, struct lttng_consumer_stream, node);
+               lttng::utils::container_of(node, &lttng_consumer_stream::node);
 
        pthread_mutex_destroy(&stream->lock);
        free(stream);
@@ -1075,10 +1075,12 @@ void consumer_stream_destroy(struct lttng_consumer_stream *stream,
                if (stream->globally_visible) {
                        pthread_mutex_lock(&the_consumer_data.lock);
                        pthread_mutex_lock(&stream->chan->lock);
+
                        pthread_mutex_lock(&stream->lock);
                        /* Remove every reference of the stream in the consumer. */
                        consumer_stream_delete(stream, ht);
 
+
                        destroy_close_stream(stream);
 
                        /* Update channel's refcount of the stream. */
This page took 0.0239 seconds and 4 git commands to generate.