OSDN Git Service
(root)
/
android-x86
/
external-alsa-lib.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
485930e
)
ucm: fix parse_get_safe_name() - safe name must be checked after substitution
author
Jaroslav Kysela
<perex@perex.cz>
Fri, 3 Jul 2020 12:48:18 +0000
(14:48 +0200)
committer
Jaroslav Kysela
<perex@perex.cz>
Fri, 3 Jul 2020 12:48:18 +0000
(14:48 +0200)
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
src/ucm/parser.c
patch
|
blob
|
history
diff --git
a/src/ucm/parser.c
b/src/ucm/parser.c
index
3b7fc93
..
d034b85
100644
(file)
--- a/
src/ucm/parser.c
+++ b/
src/ucm/parser.c
@@
-234,9
+234,14
@@
int parse_get_safe_name(snd_use_case_mgr_t *uc_mgr, snd_config_t *n,
if (err < 0)
return err;
}
- if (!parse_is_name_safe(id))
+ err = get_string3(uc_mgr, id, name);
+ if (err < 0)
+ return err;
+ if (!parse_is_name_safe(*name)) {
+ free(*name);
return -EINVAL;
- return get_string3(uc_mgr, id, name);
+ }
+ return 0;
}
/*