X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fcommon%2Fkernel-consumer%2Fkernel-consumer.c;h=29a27134f0e372c8c8295114048537a07dcc6453;hb=2d54bfb67f451a491c8cdfb6f6caea3981dc21a8;hp=196da6633353a44ea6f73821494642e0cd7539a3;hpb=a9d36096fd1bfbeb7c55a5cfc97523512237f0d4;p=lttng-tools.git diff --git a/src/common/kernel-consumer/kernel-consumer.c b/src/common/kernel-consumer/kernel-consumer.c index 196da6633..29a27134f 100644 --- a/src/common/kernel-consumer/kernel-consumer.c +++ b/src/common/kernel-consumer/kernel-consumer.c @@ -1145,7 +1145,7 @@ end_destroy_channel: ret = consumer_send_status_msg(sock, ret_code); if (ret < 0) { /* Somehow, the session daemon is not responding anymore. */ - goto end_nosignal; + goto error_rotate_channel; } if (channel) { /* Rotate the streams that are ready right now. */ @@ -1155,8 +1155,9 @@ end_destroy_channel: ERR("Rotate ready streams failed"); } } - break; +error_rotate_channel: + goto end_nosignal; } case LTTNG_CONSUMER_INIT: { @@ -1249,6 +1250,8 @@ end_destroy_channel: msg.u.close_trace_chunk.close_command.value; const uint64_t relayd_id = msg.u.close_trace_chunk.relayd_id.value; + struct lttcomm_consumer_close_trace_chunk_reply reply; + char path[LTTNG_PATH_MAX]; ret_code = lttng_consumer_close_trace_chunk( msg.u.close_trace_chunk.relayd_id.is_set ? @@ -1259,8 +1262,18 @@ end_destroy_channel: (time_t) msg.u.close_trace_chunk.close_timestamp, msg.u.close_trace_chunk.close_command.is_set ? &close_command : - NULL); - goto end_msg_sessiond; + NULL, path); + reply.ret_code = ret_code; + reply.path_length = strlen(path) + 1; + ret = lttcomm_send_unix_sock(sock, &reply, sizeof(reply)); + if (ret != sizeof(reply)) { + goto error_fatal; + } + ret = lttcomm_send_unix_sock(sock, path, reply.path_length); + if (ret != reply.path_length) { + goto error_fatal; + } + goto end_nosignal; } case LTTNG_CONSUMER_TRACE_CHUNK_EXISTS: {