summaryrefslogtreecommitdiffstats
path: root/src/modules/bluetooth
diff options
context:
space:
mode:
authorMarc-André Lureau <marc-andre.lureau@nokia.com>2009-02-13 12:18:14 +0200
committerMarc-André Lureau <marc-andre.lureau@nokia.com>2009-02-18 15:20:48 +0200
commitb4c391ee5eaa61c31fa297b6b3f6e3a65d662948 (patch)
tree1c1e1e92d0af0fd0e88dcd66cabb2115eaf66b66 /src/modules/bluetooth
parentb51e6135e87221b05acb1e8796d28bec1cf06dff (diff)
bluetooth: don't crash on pa_thread_mq_done() if pa_init() fail
Diffstat (limited to 'src/modules/bluetooth')
-rw-r--r--src/modules/bluetooth/module-bluetooth-device.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/bluetooth/module-bluetooth-device.c b/src/modules/bluetooth/module-bluetooth-device.c
index 35338dcf..748a2d4d 100644
--- a/src/modules/bluetooth/module-bluetooth-device.c
+++ b/src/modules/bluetooth/module-bluetooth-device.c
@@ -1517,9 +1517,9 @@ static void stop_thread(struct userdata *u) {
u->source = NULL;
}
- pa_thread_mq_done(&u->thread_mq);
-
if (u->rtpoll) {
+ pa_thread_mq_done(&u->thread_mq);
+
pa_rtpoll_free(u->rtpoll);
u->rtpoll = NULL;
}