mirror of
https://github.com/mpv-player/mpv
synced 2025-03-25 04:38:01 +00:00
ao_alsa: handle underruns in get_space() too
This is essentially optional. But it will give the higher level code a better guarantee that underruns were tested.
This commit is contained in:
parent
1d25d7fe92
commit
52f3dee16a
@ -970,6 +970,8 @@ static int get_space(struct ao *ao)
|
||||
check_device_present(ao, space);
|
||||
goto alsa_error;
|
||||
}
|
||||
if (space == -EPIPE)
|
||||
handle_underrun(ao);
|
||||
|
||||
if (space > p->buffersize || space < 0) // Buffer underrun?
|
||||
space = p->buffersize;
|
||||
|
Loading…
Reference in New Issue
Block a user