projects
/
platform
/
upstream
/
pulseaudio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
11cde92
)
loopback: Fix crashes
author
Maarten Lankhorst
<m.b.lankhorst@gmail.com>
Sun, 22 Jan 2012 13:11:23 +0000
(14:11 +0100)
committer
Colin Guthrie
<colin@mageia.org>
Mon, 30 Jan 2012 11:17:08 +0000
(11:17 +0000)
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.
src/modules/module-loopback.c
patch
|
blob
|
history
diff --git
a/src/modules/module-loopback.c
b/src/modules/module-loopback.c
index
5291258
..
1f2ef91
100644
(file)
--- a/
src/modules/module-loopback.c
+++ b/
src/modules/module-loopback.c
@@
-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();