]> git.alsa-project.org Git - alsa-lib.git/commitdiff
ucm: fix Path condition - substitute Path
authorJaroslav Kysela <perex@perex.cz>
Wed, 24 Apr 2024 12:47:27 +0000 (14:47 +0200)
committerJaroslav Kysela <perex@perex.cz>
Wed, 24 Apr 2024 12:48:13 +0000 (14:48 +0200)
Use the appropriate variable for access/eaccess call.

Fixes: https://github.com/alsa-project/alsa-lib/issues/395
Fixes: ef6463a2 ("ucm: fix Path condition - substitute Path and Mode fields")
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
src/ucm/ucm_cond.c

index 70effda03f06620fcc76c718734144aad8fb2441..bc4444e3f37913952eff77597c52a90483348133 100644 (file)
@@ -315,9 +315,9 @@ static int if_eval_path(snd_use_case_mgr_t *uc_mgr, snd_config_t *eval)
        if (err < 0)
                return err;
 #ifdef HAVE_EACCESS
-       err = eaccess(path, amode);
+       err = eaccess(s, amode);
 #else
-       err = access(path, amode);
+       err = access(s, amode);
 #endif
        free(s);
        return err ? 0 : 1;