rtsp-stream: Plug memory leak

Attaching a GSource to a context will increase the refcount. The idle
source will never be free'd since the initial reference is never
dropped.
This commit is contained in:
Linus Svensson 2018-11-06 18:10:56 +01:00 committed by Sebastian Dröge
parent 2065298d6d
commit 1c4d3b36fb

View file

@ -4400,6 +4400,7 @@ on_message_sent (gpointer user_data)
g_source_set_callback (idle_src, (GSourceFunc) cb_send_tcp_message,
g_object_ref (stream), g_object_unref);
g_source_attach (idle_src, priv->watch_context);
g_source_unref (idle_src);
} else {
/* appsink is running this callback */
send_tcp_message (stream, idx);