Fix multi-session UST handling combined with shm fd teardown
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 16 Nov 2011 01:24:41 +0000 (20:24 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Wed, 16 Nov 2011 01:24:41 +0000 (20:24 -0500)
commit7ad0a0cb283d4004cf9274df8eec4e3530864fc7
tree69b8d2c3cc0c2f3e2e45889f28631ddad800f28a
parent464dd62d5617322366e321877b440951e00a0152
Fix multi-session UST handling combined with shm fd teardown

shm fd is used as unique identifier for the channel when passing the
stream fds to the consumer. However, closing the fd reuses the same
identifier for the next round, thus getting the same consumer
channel/streams as the previous one. This causes multi-session tracing
to only work for the first session, not the following ones.

So instead of doing a channel lookup on add channel and a stream lookup
upon add stream, we "steal" the identifier. We still lookup the channel
identifier upon stream add though: this means the sessiond needs to keep
the channel shm fd open until it has finished sending all stream fds to
the consumer. For kernel consumer, the update operation still does a
stream id lookup.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
liblttng-consumer/lttng-consumer.c
liblttng-ustconsumer/lttng-ustconsumer.c
lttng-sessiond/ust-consumer.c
This page took 0.025102 seconds and 4 git commands to generate.