alsa: Handle the "profile" modarg in module-alsa-card

This commit is contained in:
Tanu Kaskinen 2011-10-03 18:11:47 +03:00 committed by Arun Raghavan
parent 9a1eee5c43
commit 12fe756993

View file

@ -294,6 +294,7 @@ int pa__init(pa_module *m) {
struct userdata *u; struct userdata *u;
pa_reserve_wrapper *reserve = NULL; pa_reserve_wrapper *reserve = NULL;
const char *description; const char *description;
const char *profile = NULL;
char *fn = NULL; char *fn = NULL;
pa_bool_t namereg_fail = FALSE; pa_bool_t namereg_fail = FALSE;
@ -390,6 +391,9 @@ int pa__init(pa_module *m) {
goto fail; goto fail;
} }
if ((profile = pa_modargs_get_value(ma, "profile", NULL)))
pa_card_new_data_set_profile(&data, profile);
u->card = pa_card_new(m->core, &data); u->card = pa_card_new(m->core, &data);
pa_card_new_data_done(&data); pa_card_new_data_done(&data);