X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fclear.c;h=e699caffc51ad24c6ae560aa253622beca46888f;hb=48c77bf7ccc9a88c229432a6db4871940914bedb;hp=03abbd8e19090c55301c393936824a5bfc2a2c2d;hpb=ab5be9fa2eb5ba9600a82cd18fd3cfcbac69169a;p=lttng-tools.git diff --git a/src/bin/lttng-sessiond/clear.c b/src/bin/lttng-sessiond/clear.c index 03abbd8e1..e699caffc 100644 --- a/src/bin/lttng-sessiond/clear.c +++ b/src/bin/lttng-sessiond/clear.c @@ -6,7 +6,6 @@ */ #define _LGPL_SOURCE -#include #include #include #include @@ -194,6 +193,16 @@ int cmd_clear_session(struct ltt_session *session, int *sock_fd) goto end; } } + + /* + * Open a packet in every stream of the session to ensure that + * viewers can correctly identify the boundaries of the periods + * during which tracing was active for this session. + */ + ret = session_open_packets(session); + if (ret != LTTNG_OK) { + goto end; + } } ret = LTTNG_OK; end: