If the media has been managed by a session media, it should not be
cached in the client any longer. The GstRTSPSessionMedia object is now
responsible for unpreparing the GstRTSPMedia object using
gst_rtsp_media_unprepare(). Unprepare the media when finalizing the
session media.
https://bugzilla.gnome.org/show_bug.cgi?id=739112
/* if we stil have no media, error */
if (sessmedia == NULL)
goto sessmedia_unavailable;
+
+ /* don't cache media anymore */
+ if (priv->path)
+ g_free (priv->path);
+ priv->path = NULL;
+ if (priv->media)
+ g_object_unref (priv->media);
+ priv->media = NULL;
} else {
g_object_unref (media);
}
gst_rtsp_session_media_set_state (media, GST_STATE_NULL);
+ gst_rtsp_media_unprepare (priv->media);
+
g_ptr_array_unref (priv->transports);
g_free (priv->path);