X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=ltt-sessiond%2Fmain.c;h=98738928464290a8b1406bf21be06e54c26c9b68;hp=8c113fab3505058014369b592ac1a209b7cae184;hb=6beb22421cf1641eb09813c167741e27cf5f58dc;hpb=bd5bb7089d7b2a6e1d082a16abee82b5544e2c0f diff --git a/ltt-sessiond/main.c b/ltt-sessiond/main.c index 8c113fab3..987389284 100644 --- a/ltt-sessiond/main.c +++ b/ltt-sessiond/main.c @@ -637,9 +637,11 @@ static int create_trace_dir(struct ltt_kernel_session *session) // TODO: recursive create dir ret = mkdir(chan->pathname, S_IRWXU | S_IRWXG ); if (ret < 0) { - perror("mkdir trace path"); - ret = -errno; - goto error; + if (ret != EEXIST) { + perror("mkdir trace path"); + ret = -errno; + goto error; + } } } @@ -1514,8 +1516,11 @@ static int set_kconsumerd_sockets(void) ret = mkdir(KCONSUMERD_PATH, S_IRWXU | S_IRWXG); if (ret < 0) { - ERR("Failed to create " KCONSUMERD_PATH); - goto error; + if (errno != EEXIST) { + ERR("Failed to create " KCONSUMERD_PATH); + goto error; + } + ret = 0; } /* Create the kconsumerd error unix socket */