Fix session list locking
The session list lock was not used correctly when a client requested the
session list. The session counter and iteration over the list is
protected by a single critical section now.
Move get_lttng_sessions to the main.c in order to remove lttng.h
dependency to session.c/.h and to make easier for the session list
locking.
Remove the get_session_count which is useless since the counter is now
in the session list structure. Access the counter by locking the list
and reading 'count'.
This adds two function to lock and unlock the session list.
Reported-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: David Goulet <david.goulet@polymtl.ca>
This page took 0.025623 seconds and 4 git commands to generate.