Fix: free ust channel object after grace period in consumer
[lttng-tools.git] / src / common / consumer.c
index 2dd31ffd6c432af12018b00629c9482fbfbc93bd..9a3bf86e797d6213b40b0ed1811f116417f89685 100644 (file)
@@ -285,6 +285,17 @@ static void free_channel_rcu(struct rcu_head *head)
        struct lttng_consumer_channel *channel =
                caa_container_of(node, struct lttng_consumer_channel, node);
 
+       switch (consumer_data.type) {
+       case LTTNG_CONSUMER_KERNEL:
+               break;
+       case LTTNG_CONSUMER32_UST:
+       case LTTNG_CONSUMER64_UST:
+               lttng_ustconsumer_free_channel(channel);
+               break;
+       default:
+               ERR("Unknown consumer_data type");
+               abort();
+       }
        free(channel);
 }
 
This page took 0.023623 seconds and 4 git commands to generate.