X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fclient.c;h=30ec1111998e44e85bb3c498014710d3903486b3;hp=327c1fe1706efabaefdf9dd2a3c5dc7fb4865c3e;hb=022349df3783b538b41cf4a3cd55e7b231603bdd;hpb=0f68efb616cd046543e5fc5a091466ec26df2216 diff --git a/src/bin/lttng-sessiond/client.c b/src/bin/lttng-sessiond/client.c index 327c1fe17..30ec11119 100644 --- a/src/bin/lttng-sessiond/client.c +++ b/src/bin/lttng-sessiond/client.c @@ -38,6 +38,7 @@ #include "testpoint.h" #include "utils.h" #include "manage-consumer.h" +#include "clear.h" static bool is_root; @@ -747,6 +748,7 @@ static int process_client_msg(struct command_ctx *cmd_ctx, int *sock, case LTTNG_ROTATION_GET_INFO: case LTTNG_ROTATION_SET_SCHEDULE: case LTTNG_SESSION_LIST_ROTATION_SCHEDULES: + case LTTNG_CLEAR_SESSION: need_domain = 0; break; default: @@ -1850,7 +1852,8 @@ error_add_context: } ret = cmd_rotate_session(cmd_ctx->session, &rotate_return, - false); + false, + LTTNG_TRACE_CHUNK_COMMAND_TYPE_MOVE_TO_COMPLETED); if (ret < 0) { ret = -ret; goto error; @@ -1934,6 +1937,11 @@ error_add_context: ret = LTTNG_OK; break; } + case LTTNG_CLEAR_SESSION: + { + ret = cmd_clear_session(cmd_ctx->session, sock); + break; + } default: ret = LTTNG_ERR_UND; break;