mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-31 22:25:35 -04:00
pcm: Don't assert in _snd_pcm_hw_params_internal()
It's no fatal error from sw params, and it's really bad habit to use assert() and abort the operation as a system library. Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
8551fe2587
commit
a5e5e3cd3c
1 changed files with 2 additions and 1 deletions
|
|
@ -2361,7 +2361,8 @@ int _snd_pcm_hw_params_internal(snd_pcm_t *pcm, snd_pcm_hw_params_t *params)
|
|||
memset(&sw, 0, sizeof(sw));
|
||||
snd_pcm_sw_params_default(pcm, &sw);
|
||||
err = snd_pcm_sw_params(pcm, &sw);
|
||||
assert(err >= 0);
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
||||
if (pcm->mmap_rw ||
|
||||
pcm->access == SND_PCM_ACCESS_MMAP_INTERLEAVED ||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue