mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-03 09:01:50 -05:00
source-output: Fix rewinding bug
Currently the rewind logic for the source output is broken if the output does not implement a process_rewind() callback. In that case, the read index of the delay memblockq is rewound. This is wrong, because the data that is going to be re-written was not yet read. Instead the write index should be rewound and the read index left untouched. This is the reason for the rewind glitches of monitor sources.
This commit is contained in:
parent
f89d64b98e
commit
1240afabfa
1 changed files with 1 additions and 1 deletions
|
|
@ -866,7 +866,7 @@ void pa_source_output_process_rewind(pa_source_output *o, size_t nbytes /* in so
|
|||
pa_resampler_rewind(o->thread_info.resampler, nbytes);
|
||||
|
||||
} else
|
||||
pa_memblockq_rewind(o->thread_info.delay_memblockq, nbytes);
|
||||
pa_memblockq_seek(o->thread_info.delay_memblockq, - ((int64_t) nbytes), PA_SEEK_RELATIVE, true);
|
||||
}
|
||||
|
||||
/* Called from thread context */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue