From: Jérémie Galarneau Date: Tue, 18 Nov 2014 14:35:48 +0000 (-0500) Subject: Fix: Missing rcu_read_lock in get_session_max_subbuf_size() X-Git-Tag: v2.6.0-rc4~49 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=7756a65dc449aad4ab12e2fbc319c4cebeeaf9b3;p=lttng-tools.git Fix: Missing rcu_read_lock in get_session_max_subbuf_size() Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c index e9427eb24..49243ae26 100644 --- a/src/bin/lttng-sessiond/cmd.c +++ b/src/bin/lttng-sessiond/cmd.c @@ -3036,12 +3036,14 @@ static uint64_t get_session_max_subbuf_size(struct ltt_session *session) struct ltt_ust_channel *uchan; struct ltt_ust_session *usess = session->ust_session; + rcu_read_lock(); cds_lfht_for_each_entry(usess->domain_global.channels->ht, &iter.iter, uchan, node.node) { if (uchan->attr.subbuf_size > max_size) { max_size = uchan->attr.subbuf_size; } } + rcu_read_unlock(); } return max_size;