stream: clear session and caps for reuse

Set the session and caps to NULL after unref otherwise we might unref
them again later.

See https://bugzilla.gnome.org/show_bug.cgi?id=698376
This commit is contained in:
Ognyan Tonchev 2013-04-22 16:09:22 +02:00 committed by Wim Taymans
parent bba7c4042d
commit 6081f91351

View file

@ -1220,8 +1220,10 @@ gst_rtsp_stream_leave_bin (GstRTSPStream * stream, GstBin * bin,
priv->send_src[1] = NULL; priv->send_src[1] = NULL;
g_object_unref (priv->session); g_object_unref (priv->session);
priv->session = NULL;
if (priv->caps) if (priv->caps)
gst_caps_unref (priv->caps); gst_caps_unref (priv->caps);
priv->caps = NULL;
priv->is_joined = FALSE; priv->is_joined = FALSE;
g_mutex_unlock (&priv->lock); g_mutex_unlock (&priv->lock);