#define _GNU_SOURCE
#include <limits.h>
+#include <inttypes.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
* The caller MUST acquire the session list lock before.
* Returns the unique identifier for the session.
*/
-static unsigned int add_session_list(struct ltt_session *ls)
+static uint64_t add_session_list(struct ltt_session *ls)
{
assert(ls);
* up and, if valid, assign it to the session.
*/
- DBG("Tracing session %s created with ID %u by UID %d GID %d", name,
- new_session->id, new_session->uid, new_session->gid);
+ DBG("Tracing session %s created with ID %" PRIu64 " by UID %d GID %d",
+ name, new_session->id, new_session->uid, new_session->gid);
return LTTNG_OK;
* Session unique ID generator. The session list lock MUST be
* upon update and read of this counter.
*/
- unsigned int next_uuid;
+ uint64_t next_uuid;
/* Linked list head */
struct cds_list_head head;
pthread_mutex_t lock;
struct cds_list_head list;
int enabled; /* enabled/started flag */
- unsigned int id; /* session unique identifier */
+ uint64_t id; /* session unique identifier */
/* UID/GID of the user owning the session */
uid_t uid;
gid_t gid;
struct consumer_output *consumer;
struct consumer_output *tmp_consumer;
/* Tracing session id */
- unsigned int id;
+ uint64_t id;
/* Session is started and active */
unsigned int started;
/* Tell or not if the session has to output the traces. */