module-rtp-recv: Request proper rewind after underrun

This commit is contained in:
Maarten Bosmans 2011-01-12 07:34:28 +01:00
parent 27db0603d6
commit 72b90ea8ac

View file

@ -375,7 +375,9 @@ static int rtpoll_work_cb(pa_rtpoll_item *i) {
if (pa_memblockq_is_readable(s->memblockq) && if (pa_memblockq_is_readable(s->memblockq) &&
s->sink_input->thread_info.underrun_for > 0) { s->sink_input->thread_info.underrun_for > 0) {
pa_log_debug("Requesting rewind due to end of underrun"); pa_log_debug("Requesting rewind due to end of underrun");
pa_sink_input_request_rewind(s->sink_input, 0, FALSE, TRUE, FALSE); pa_sink_input_request_rewind(s->sink_input,
(size_t) (s->sink_input->thread_info.underrun_for == (uint64_t) -1 ? 0 : s->sink_input->thread_info.underrun_for),
FALSE, TRUE, FALSE);
} }
return 1; return 1;