X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Ftrace-ust.c;h=569599af28c5e7fb6658855f99276d9ef92ea736;hp=b1bae1794ab70560d7e4e74c4520793659de4ac9;hb=d070c424703336e9cca9d1603e1a81bee5b59560;hpb=ce75e27ac20a5eb37fd1334e88a59a0cb91cb397 diff --git a/src/bin/lttng-sessiond/trace-ust.c b/src/bin/lttng-sessiond/trace-ust.c index b1bae1794..569599af2 100644 --- a/src/bin/lttng-sessiond/trace-ust.c +++ b/src/bin/lttng-sessiond/trace-ust.c @@ -1161,7 +1161,8 @@ static void destroy_domain_global(struct ltt_ust_domain_global *dom) } /* - * Cleanup ust session structure + * Cleanup ust session structure, keeping data required by + * destroy notifier. * * Should *NOT* be called with RCU read-side lock held. */ @@ -1197,9 +1198,13 @@ void trace_ust_destroy_session(struct ltt_ust_session *session) buffer_reg_uid_destroy(reg, session->consumer); } - consumer_output_put(session->consumer); - fini_pid_tracker(&session->pid_tracker); lttng_trace_chunk_put(session->current_trace_chunk); +} + +/* Free elements needed by destroy notifiers. */ +void trace_ust_free_session(struct ltt_ust_session *session) +{ + consumer_output_put(session->consumer); free(session); }