From: Jérémie Galarneau Date: Tue, 18 Nov 2014 18:37:29 +0000 (-0500) Subject: Fix: Missing rcu_read_lock in ust_app_get_nb_stream() X-Git-Tag: v2.4.3~29 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=19152ffe0ff82476f335b57948915e9146fb3626;p=lttng-tools.git Fix: Missing rcu_read_lock in ust_app_get_nb_stream() Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/ust-app.c b/src/bin/lttng-sessiond/ust-app.c index b0e47a086..0ae02c324 100644 --- a/src/bin/lttng-sessiond/ust-app.c +++ b/src/bin/lttng-sessiond/ust-app.c @@ -5124,10 +5124,12 @@ unsigned int ust_app_get_nb_stream(struct ltt_ust_session *usess) cds_list_for_each_entry(reg, &usess->buffer_reg_uid_list, lnode) { struct buffer_reg_channel *reg_chan; + rcu_read_lock(); cds_lfht_for_each_entry(reg->registry->channels->ht, &iter.iter, reg_chan, node.node) { ret += reg_chan->stream_count; } + rcu_read_unlock(); } break; }