mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-12-22 08:56:52 -05:00
core: memory leak, fix ref counting when moving streams
This commit is contained in:
parent
dcd4a73df9
commit
9ae8ca2c37
4 changed files with 40 additions and 12 deletions
|
|
@ -466,8 +466,12 @@ pa_queue *pa_source_move_all_start(pa_source *s) {
|
|||
for (o = PA_SOURCE_OUTPUT(pa_idxset_first(s->outputs, &idx)); o; o = n) {
|
||||
n = PA_SOURCE_OUTPUT(pa_idxset_next(s->outputs, &idx));
|
||||
|
||||
pa_source_output_ref(o);
|
||||
|
||||
if (pa_source_output_start_move(o) >= 0)
|
||||
pa_queue_push(q, pa_source_output_ref(o));
|
||||
pa_queue_push(q, o);
|
||||
else
|
||||
pa_source_output_unref(o);
|
||||
}
|
||||
|
||||
return q;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue