#ifndef _LTT_SESSION_H
#define _LTT_SESSION_H
+#include <limits.h>
#include <urcu/list.h>
#include <common/hashtable/hashtable.h>
*/
struct ltt_session {
char name[NAME_MAX];
+ char hostname[HOST_NAME_MAX]; /* Local hostname. */
struct ltt_kernel_session *kernel_session;
struct ltt_ust_session *ust_session;
/*
struct snapshot snapshot;
/* Indicate if the session has to output the traces or not. */
unsigned int output_traces;
+ /*
+ * This session is in snapshot mode. This means that every channel enabled
+ * will be set in overwrite mode and mmap. It is considered exclusively for
+ * snapshot purposes.
+ */
+ unsigned int snapshot_mode;
+ /*
+ * Timer set when the session is created for live reading.
+ */
+ int live_timer;
};
/* Prototypes */
void session_unlock(struct ltt_session *session);
void session_unlock_list(void);
-struct ltt_session *session_find_by_name(char *name);
+struct ltt_session *session_find_by_name(const char *name);
struct ltt_session_list *session_get_list(void);
int session_access_ok(struct ltt_session *session, uid_t uid, gid_t gid);