ucm: split conf_file_name and conf_dir_name

With ucm2, the file name might differ from the directory
name. Also, allocate those fields.

Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
Jaroslav Kysela 2020-01-15 10:31:56 +01:00
parent b34715004f
commit fe6425af75
5 changed files with 37 additions and 17 deletions

View file

@ -31,7 +31,7 @@
static char *rval_conf_name(snd_use_case_mgr_t *uc_mgr)
{
if (uc_mgr->conf_file_name[0])
if (uc_mgr->conf_file_name && uc_mgr->conf_file_name[0])
return strdup(uc_mgr->conf_file_name);
return NULL;
}