Fix: define _LGPL_SOURCE in C files
[lttng-tools.git] / src / bin / lttng-sessiond / cmd.c
index 17091de09ec66d9bd5b6028bbf04b90c7a99d5ff..41b8502cfee8aeaab2c46e97d0b18a21e43bbdb1 100644 (file)
@@ -16,6 +16,7 @@
  */
 
 #define _GNU_SOURCE
+#define _LGPL_SOURCE
 #include <assert.h>
 #include <inttypes.h>
 #include <urcu/list.h>
@@ -1848,7 +1849,9 @@ int cmd_start_trace(struct ltt_session *session)
         * possible to enable channel thus inform the client.
         */
        if (usess && usess->domain_global.channels) {
+               rcu_read_lock();
                nb_chan += lttng_ht_get_count(usess->domain_global.channels);
+               rcu_read_unlock();
        }
        if (ksession) {
                nb_chan += ksession->channel_count;
This page took 0.026402 seconds and 5 git commands to generate.