Added context handling for snd_config_expand.

PCM slave configuration is now dynamic.
This commit is contained in:
Jaroslav Kysela 2001-06-16 22:03:23 +00:00
parent 43455a9268
commit 1e0c53a11c
26 changed files with 259 additions and 218 deletions

View file

@ -355,10 +355,12 @@ int _snd_pcm_linear_open(snd_pcm_t **pcmp, const char *name,
if (err < 0)
return err;
if (snd_pcm_format_linear(sformat) != 1) {
snd_config_delete(sconf);
SNDERR("slave format is not linear");
return -EINVAL;
}
err = snd_pcm_open_slave(&spcm, root, sconf, stream, mode);
snd_config_delete(sconf);
if (err < 0)
return err;
err = snd_pcm_linear_open(pcmp, name, sformat, spcm, 1);