mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-11-04 13:30:08 -05:00
Added context handling for snd_config_expand.
PCM slave configuration is now dynamic.
This commit is contained in:
parent
43455a9268
commit
1e0c53a11c
26 changed files with 259 additions and 218 deletions
|
|
@ -752,11 +752,14 @@ int _snd_pcm_plug_open(snd_pcm_t **pcmp, const char *name,
|
|||
ttable = malloc(MAX_CHANNELS * MAX_CHANNELS * sizeof(*ttable));
|
||||
err = snd_pcm_route_load_ttable(tt, ttable, MAX_CHANNELS, MAX_CHANNELS,
|
||||
&cused, &sused, -1);
|
||||
if (err < 0)
|
||||
if (err < 0) {
|
||||
snd_config_delete(sconf);
|
||||
return err;
|
||||
}
|
||||
}
|
||||
|
||||
err = snd_pcm_open_slave(&spcm, root, sconf, stream, mode);
|
||||
snd_config_delete(sconf);
|
||||
if (err < 0)
|
||||
return err;
|
||||
err = snd_pcm_plug_open(pcmp, name, ttable, MAX_CHANNELS, cused, sused, spcm, 1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue