X-Git-Url: https://git.lttng.org/?a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fmain.c;h=76d087a1e5c90c1198afa870f19be9a4ae526d49;hb=b723c447e99a0aa57fd3d5313273c05bb416a517;hp=10802aa7b2cc66d87d0946ee53623b05b47a1c0f;hpb=e822af72904352465fe4da8136674ebc6b54a6e1;p=lttng-tools.git diff --git a/src/bin/lttng-sessiond/main.c b/src/bin/lttng-sessiond/main.c index 10802aa7b..76d087a1e 100644 --- a/src/bin/lttng-sessiond/main.c +++ b/src/bin/lttng-sessiond/main.c @@ -5584,12 +5584,13 @@ int main(int argc, char **argv) /* Check if daemon is UID = 0 */ is_root = !getuid(); + if (create_lttng_rundir()) { + retval = -1; + goto exit_init_data; + } + if (is_root) { /* Create global run dir with root access */ - if (create_lttng_rundir()) { - retval = -1; - goto exit_init_data; - } kernel_channel_monitor_pipe = lttng_pipe_open(0); if (!kernel_channel_monitor_pipe) {