- alloc_path = config_get_default_path();
- if (alloc_path == NULL) {
- ERR("Unable to find config directory");
- ret = CMD_ERROR;
- goto error;
- }
-
- path = config_generate_dir_path(alloc_path);
- if (path == NULL) {
- ret = CMD_FATAL;
- goto error;
- }
-
- ret = config_init(path);
- if (ret < 0) {
- ERR("Init config directory and file failed");
- ret = CMD_ERROR;
- goto error;
- }
-
- ret = config_add_session_name(path, opt_session_name);