-/*
- * create_config_dir
- *
- * Create the empty config dir.
- */
-static int create_config_dir(char *path)
-{
- int ret;
-
- /* Create session directory .lttng */
- ret = mkdir(path, S_IRWXU | S_IRGRP | S_IXGRP);
- if (ret < 0) {
- if (errno == EEXIST) {
- ERR("Session already exist at %s", path);
- } else {
- perror("mkdir config");
- ERR("Couldn't init config directory at %s", path);
- }
- ret = -errno;
- goto error;
- }
-
-error:
- return ret;
-}
-