mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
loopback: Fix crashes
Flush the message queue before tearing down, and dest==NULL is valid in case moving failed. With this my module-loopback finally no longer causes frequent crashes.
This commit is contained in:
parent
11cde92fda
commit
2c652b43f9
1 changed files with 3 additions and 0 deletions
|
|
@ -136,6 +136,7 @@ static void teardown(struct userdata *u) {
|
|||
pa_assert(u);
|
||||
pa_assert_ctl_context();
|
||||
|
||||
pa_asyncmsgq_flush(u->asyncmsgq, 0);
|
||||
if (u->sink_input)
|
||||
pa_sink_input_unlink(u->sink_input);
|
||||
|
||||
|
|
@ -360,6 +361,8 @@ static void source_output_moving_cb(pa_source_output *o, pa_source *dest) {
|
|||
pa_proplist *p;
|
||||
const char *n;
|
||||
struct userdata *u;
|
||||
if (!dest)
|
||||
return;
|
||||
|
||||
pa_source_output_assert_ref(o);
|
||||
pa_assert_ctl_context();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue