mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-30 04:00:37 +00:00
client: set session media to NULL without the lock
We need to set session medias to NULL without the client lock otherwise we can end up in a deadlock if another thread is waiting for the lock and media unprepare is also waiting for that thread to end. https://bugzilla.gnome.org/show_bug.cgi?id=737690
This commit is contained in:
parent
1badcd83c3
commit
6c0c90c9d2
1 changed files with 4 additions and 3 deletions
|
@ -346,9 +346,6 @@ client_unwatch_session (GstRTSPClient * client, GstRTSPSession * session,
|
|||
priv->session_removed_id = 0;
|
||||
}
|
||||
|
||||
/* unlink all media managed in this session */
|
||||
gst_rtsp_session_filter (session, filter_session_media, client);
|
||||
|
||||
/* remove the session */
|
||||
g_object_unref (session);
|
||||
}
|
||||
|
@ -357,6 +354,10 @@ static GstRTSPFilterResult
|
|||
cleanup_session (GstRTSPClient * client, GstRTSPSession * sess,
|
||||
gpointer user_data)
|
||||
{
|
||||
/* unlink all media managed in this session. This needs to happen
|
||||
* without the client lock, so we really want to do it here. */
|
||||
gst_rtsp_session_filter (sess, filter_session_media, client);
|
||||
|
||||
return GST_RTSP_FILTER_REMOVE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue