mirror of
https://github.com/alsa-project/alsa-utils
synced 2024-12-22 07:06:30 +01:00
Fixed bug with space in mixer device name.
This commit is contained in:
parent
adcf1ed5d2
commit
55a39d6eda
1 changed files with 2 additions and 4 deletions
|
@ -188,12 +188,10 @@ int main(int argc, char **argv)
|
|||
} else if (sscanf(argv[i], "%d:%d", &left, &right)==2) {
|
||||
} else if (sscanf(argv[i], "%d", &left)==1) {
|
||||
right = left;
|
||||
} else if (sscanf(argv[i], "%s", device_name)==1) {
|
||||
} else {
|
||||
fprintf(stderr, "Wrong keyword: %s\n", argv[i]);
|
||||
exit(1);
|
||||
strncpy(device_name, argv[i], sizeof(device_name));
|
||||
device_name[sizeof(device_name)-1] = 0;
|
||||
}
|
||||
|
||||
}
|
||||
Mixer mixer(card,device);
|
||||
|
||||
|
|
Loading…
Reference in a new issue