mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-28 04:31:06 +00:00
Revert "client: never call gst_rtsp_media_unprepare, let gst_rtsp_media_finalize do it"
This reverts commit ba5b78ff2f
.
We can't use the refcount to trigger unprepare because it is the unprepare call
that removes the last refcount after all messages are consumed. What we should
probably do is make a prepared refcount and only unprepare when the refcount
reaches 0.
This commit is contained in:
parent
119674a828
commit
38addd7822
1 changed files with 2 additions and 0 deletions
|
@ -278,6 +278,7 @@ gst_rtsp_client_finalize (GObject * obj)
|
|||
if (priv->uri)
|
||||
gst_rtsp_url_free (priv->uri);
|
||||
if (priv->media) {
|
||||
gst_rtsp_media_unprepare (priv->media);
|
||||
g_object_unref (priv->media);
|
||||
}
|
||||
|
||||
|
@ -435,6 +436,7 @@ find_media (GstRTSPClient * client, GstRTSPClientState * state)
|
|||
gst_rtsp_url_free (priv->uri);
|
||||
priv->uri = NULL;
|
||||
if (priv->media) {
|
||||
gst_rtsp_media_unprepare (priv->media);
|
||||
g_object_unref (priv->media);
|
||||
}
|
||||
priv->media = NULL;
|
||||
|
|
Loading…
Reference in a new issue