pcm: hw - fix return code checking in snd_pcm_hw_hw_refine

The isse was introduced in commit 7f2d6c3

Fixes: 7f2d6c3a ("pcm: hw: change rate range syntax")
Fixes: https://github.com/alsa-project/alsa-lib/issues/271
Fixes: https://github.com/alsa-project/alsa-lib/pull/293
Signed-off-by: Gunnar Dibbern <gunnar.dibbern@lht.dlh.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
Gunnar Dibbern 2023-01-19 16:32:42 +01:00 committed by Jaroslav Kysela
parent e11ea20645
commit 2f9bbefb8d

View file

@ -356,7 +356,7 @@ static int snd_pcm_hw_hw_refine(snd_pcm_t *pcm, snd_pcm_hw_params_t *params)
if (hw->rates.min > 0) {
err = _snd_pcm_hw_param_set_minmax(params, SND_PCM_HW_PARAM_RATE,
hw->rates.min, 0, hw->rates.max + 1, -1);
if (err < 0)
return err;
}