mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-30 12:49:40 +00:00
client: call weak-unref on client->sessions from finalize
Fixes bug #596305
This commit is contained in:
parent
f8630c6c81
commit
745900dd48
1 changed files with 8 additions and 0 deletions
|
@ -85,9 +85,17 @@ static void
|
|||
gst_rtsp_client_finalize (GObject * obj)
|
||||
{
|
||||
GstRTSPClient *client = GST_RTSP_CLIENT (obj);
|
||||
GList *walk;
|
||||
|
||||
g_message ("finalize client %p", client);
|
||||
|
||||
/* remove weak-ref from sessions */
|
||||
for (walk = client->sessions; walk; walk = g_list_next (walk)) {
|
||||
GstRTSPSession *msession = (GstRTSPSession *) walk->data;
|
||||
g_object_weak_unref (G_OBJECT (msession),
|
||||
(GWeakNotify) client_session_finalized, client);
|
||||
}
|
||||
|
||||
g_list_free (client->sessions);
|
||||
|
||||
gst_rtsp_connection_free (client->connection);
|
||||
|
|
Loading…
Reference in a new issue