mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2026-02-16 22:05:18 -05:00
ucm: be more restrictive for device name with descriptor
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
e83fd7806f
commit
2da7e29c0c
1 changed files with 5 additions and 0 deletions
|
|
@ -1970,6 +1970,11 @@ static int verb_normalize_device_names(snd_use_case_mgr_t *uc_mgr, struct use_ca
|
||||||
|
|
||||||
colon = strchr(norm_name, ':');
|
colon = strchr(norm_name, ':');
|
||||||
if (colon) {
|
if (colon) {
|
||||||
|
if (colon[1] == '\0' || strchr(colon + 1, ' ')) {
|
||||||
|
snd_error(UCM, "device descriptor cannot be empty or contain spaces '%s'", orig_name);
|
||||||
|
err = -EINVAL;
|
||||||
|
goto __error;
|
||||||
|
}
|
||||||
*colon = '\0';
|
*colon = '\0';
|
||||||
index = 1;
|
index = 1;
|
||||||
do {
|
do {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue