mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-14 08:56:37 -05:00
alsa-plugin: do correct boundary check
The hw_ptr must be wrapped at the boundary value, not after. See #1941
This commit is contained in:
parent
f5908dbddf
commit
c1a0a602a5
1 changed files with 1 additions and 1 deletions
|
|
@ -318,7 +318,7 @@ snd_pcm_pipewire_process(snd_pcm_pipewire_t *pw, struct pw_buffer *b,
|
|||
io->format);
|
||||
|
||||
hw_ptr += xfer;
|
||||
if (hw_ptr > pw->boundary)
|
||||
if (hw_ptr >= pw->boundary)
|
||||
hw_ptr -= pw->boundary;
|
||||
pw->hw_ptr = hw_ptr;
|
||||
*hw_avail -= xfer;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue