gst-plugins-good: pulsesink: Fix deadlock if connecting to PA fails

Arun Raghavan arun at kemper.freedesktop.org
Fri Mar 11 09:49:47 PST 2011


Module: gst-plugins-good
Branch: master
Commit: 387f533a0733de7f6b8cb6e415f09e4fb24f151e
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-good/commit/?id=387f533a0733de7f6b8cb6e415f09e4fb24f151e

Author: Arun Raghavan <arun.raghavan at collabora.co.uk>
Date:   Fri Mar 11 23:24:31 2011 +0530

pulsesink: Fix deadlock if connecting to PA fails

Commit dd4ec22e introduced a deadlock in the failure path while trying
to connect to PulseAudio. This makes sure we drop the lock on the
resource mutex to avoid this.

https://bugzilla.gnome.org/show_bug.cgi?id=644510

---

 ext/pulse/pulsesink.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/ext/pulse/pulsesink.c b/ext/pulse/pulsesink.c
index 6ddc490..110adde 100644
--- a/ext/pulse/pulsesink.c
+++ b/ext/pulse/pulsesink.c
@@ -527,6 +527,7 @@ gst_pulseringbuffer_open_device (GstRingBuffer * buf)
   /* ERRORS */
 unlock_and_fail:
   {
+    g_mutex_unlock (pa_shared_resource_mutex);
     gst_pulsering_destroy_context (pbuf);
     pa_threaded_mainloop_unlock (mainloop);
     return FALSE;



More information about the gstreamer-commits mailing list