sessiond: add smart pointer utils for ltt_session
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 5 May 2022 19:25:39 +0000 (15:25 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Mon, 13 Jun 2022 20:34:46 +0000 (16:34 -0400)
Add `find_session_by_id` and `find_locked_session_by_id` which return
smart pointers to ltt_session. In both cases, the smart pointers make
use of ltt_session's underlying reference counting mechanism.

In the case of `find_locked_session_by_id`, the session that is returned
is locked; it is automatically unlocked (and a reference is released)
when the pointer goes out of scope. This makes it easier to write
exception-safe code that uses the ltt_session API.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: I125dc7592b8ef2de1da645029f311bf429a21767


No differences found
This page took 0.024998 seconds and 4 git commands to generate.