mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-07 13:30:03 -05:00
drop chunk argument from various drop() functions, since it doesn't make any sense if we want to guarantee always monotonously increasing read pointers; a couple of other fixes
git-svn-id: file:///home/lennart/svn/public/pulseaudio/branches/lennart@1529 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
9cc20b46b7
commit
068f5d5eef
14 changed files with 341 additions and 217 deletions
|
|
@ -73,14 +73,13 @@ static int sink_input_peek_cb(pa_sink_input *i, pa_memchunk *chunk) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
static void sink_input_drop_cb(pa_sink_input *i, const pa_memchunk *chunk, size_t length) {
|
||||
static void sink_input_drop_cb(pa_sink_input *i, size_t length) {
|
||||
struct userdata *u;
|
||||
size_t l;
|
||||
|
||||
pa_assert(i);
|
||||
u = i->userdata;
|
||||
pa_assert(u);
|
||||
pa_assert(chunk);
|
||||
pa_assert(length > 0);
|
||||
|
||||
u->peek_index += length;
|
||||
|
|
@ -93,8 +92,10 @@ static void sink_input_drop_cb(pa_sink_input *i, const pa_memchunk *chunk, size_
|
|||
|
||||
static void sink_input_kill_cb(pa_sink_input *i) {
|
||||
struct userdata *u;
|
||||
pa_assert(i && i->userdata);
|
||||
|
||||
pa_assert(i);
|
||||
u = i->userdata;
|
||||
pa_assert(u);
|
||||
|
||||
pa_sink_input_disconnect(u->sink_input);
|
||||
pa_sink_input_unref(u->sink_input);
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ int pa_rtp_send(pa_rtp_context *c, size_t size, pa_memblockq *q) {
|
|||
}
|
||||
|
||||
skip += k;
|
||||
pa_memblockq_drop(q, &chunk, k);
|
||||
pa_memblockq_drop(q, k);
|
||||
}
|
||||
|
||||
if (r < 0 || !chunk.memblock || n >= size || iov_idx >= MAX_IOVECS) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue