mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-02 09:01:46 -05:00
fix esound proto to not crash
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@2488 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
21dedcb9d9
commit
307645e621
1 changed files with 3 additions and 1 deletions
|
|
@ -1042,7 +1042,7 @@ static int do_read(connection *c) {
|
|||
}
|
||||
|
||||
if (!c->playback.current_memblock) {
|
||||
pa_assert_se(c->playback.current_memblock = pa_memblock_new(c->protocol->core->mempool, 0));
|
||||
pa_assert_se(c->playback.current_memblock = pa_memblock_new(c->protocol->core->mempool, (size_t) -1));
|
||||
c->playback.memblock_index = 0;
|
||||
|
||||
space = pa_memblock_get_length(c->playback.current_memblock);
|
||||
|
|
@ -1275,6 +1275,8 @@ static int sink_input_pop_cb(pa_sink_input *i, size_t length, pa_memchunk *chunk
|
|||
} else {
|
||||
size_t m;
|
||||
|
||||
chunk->length = PA_MIN(length, chunk->length);
|
||||
|
||||
c->playback.underrun = FALSE;
|
||||
|
||||
pa_memblockq_drop(c->input_memblockq, chunk->length);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue