From: Jérémie Galarneau Date: Fri, 17 Aug 2018 17:25:49 +0000 (-0400) Subject: Fix: add session_info object to sessions_ht X-Git-Tag: v2.11.0-rc1~126 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=577983cb5ac581ff691d650bd6c5c68719feb31f;p=lttng-tools.git Fix: add session_info object to sessions_ht The notification subsystem currently does not add the session_info structures it uses to account for session consumed sizes to its sessions_ht. This means that a new internal session is created for every channel, resulting in an incorrect accounting of session consumed sizes, and thus delayed rotations. Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/notification-thread-events.c b/src/bin/lttng-sessiond/notification-thread-events.c index e915b33b5..0f43e380b 100644 --- a/src/bin/lttng-sessiond/notification-thread-events.c +++ b/src/bin/lttng-sessiond/notification-thread-events.c @@ -1025,6 +1025,9 @@ struct session_info *find_or_create_session_info( name, uid, gid); goto end; } + + cds_lfht_add(state->sessions_ht, hash_key_str(name, lttng_ht_seed), + &sessions->sessions_ht_node); end: rcu_read_unlock(); return session;