X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-relayd%2Fmain.c;h=85c4fe9b9aca282ca2d35af5bfa18c910c261b55;hp=8f0767af373cf10c28dbdcdf078758c22c889941;hb=84fa4db56e9fbc47bfe8e6cccd9ace585eb9e396;hpb=1e791a74976525f287944e5dbb65208a3b9edf42 diff --git a/src/bin/lttng-relayd/main.c b/src/bin/lttng-relayd/main.c index 8f0767af3..85c4fe9b9 100644 --- a/src/bin/lttng-relayd/main.c +++ b/src/bin/lttng-relayd/main.c @@ -1113,10 +1113,13 @@ static int relay_create_session(const struct lttcomm_relayd_hdr *recv_hdr, ret = cmd_create_session_2_4(payload, session_name, hostname, &live_timer, &snapshot); } else { + bool has_current_chunk; + /* From 2.11 to ... */ ret = cmd_create_session_2_11(payload, session_name, hostname, &live_timer, &snapshot, &id_sessiond.value, sessiond_uuid, + &has_current_chunk, ¤t_chunk_id.value); if (lttng_uuid_is_nil(sessiond_uuid)) { /* The nil UUID is reserved for pre-2.11 clients. */ @@ -1125,7 +1128,7 @@ static int relay_create_session(const struct lttcomm_relayd_hdr *recv_hdr, goto send_reply; } id_sessiond.is_set = true; - current_chunk_id.is_set = true; + current_chunk_id.is_set = has_current_chunk; } if (ret < 0) { @@ -1147,14 +1150,6 @@ static int relay_create_session(const struct lttcomm_relayd_hdr *recv_hdr, reply.session_id = htobe64(session->id); - session->current_trace_chunk = - sessiond_trace_chunk_registry_get_anonymous_chunk( - sessiond_trace_chunk_registry, sessiond_uuid, - session->id); - if (!session->current_trace_chunk) { - ret = -1; - } - send_reply: if (ret < 0) { reply.ret_code = htobe32(LTTNG_ERR_FATAL);