notification-thread: remove fd from pollset on LPOLLHUP and friends
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Wed, 26 May 2021 20:05:16 +0000 (16:05 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Mon, 12 Jul 2021 21:35:19 +0000 (17:35 -0400)
commit34bf4f69e49d8a69331a6aa6826ef1f155e20ede
tree93987d6faeaa481f7f45d196188922cddbaa7302
parent2c8657f67ef532282ebccba79f9efa7a47ed538f
notification-thread: remove fd from pollset on LPOLLHUP and friends

When an app dies, it's possible that the notification thread gets an
epoll event (`LPOLLHUP`) that the socket was closed before it gets the
_REMOVE_TRACER_SOURCE command for that source.

In such cases, the notification thread should simply remove the file
descriptor from the pollset and drain the notification on that file
descriptor. It should _not_ remove the _source_element object from the
list.

The removal from the list should only be done when it receives the
_REMOVE_TRACER_SOURCE command.

Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: I9525315f9e92d0f6ae5e84e26b83a6b7207dce54
src/bin/lttng-sessiond/notification-thread-events.c
src/bin/lttng-sessiond/notification-thread-events.h
src/bin/lttng-sessiond/notification-thread.c
This page took 0.026676 seconds and 4 git commands to generate.