From 8da83759861c018e9d6abd79b7a1eb6c55090231 Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Thu, 19 Mar 2020 16:28:19 +1100 Subject: [PATCH] sendonly: Fix transceivers leak. Make sure to unref the transceivers array after use. --- webrtc/sendonly/webrtc-unidirectional-h264.c | 1 + 1 file changed, 1 insertion(+) diff --git a/webrtc/sendonly/webrtc-unidirectional-h264.c b/webrtc/sendonly/webrtc-unidirectional-h264.c index bb9ca8e44b..4887c7eed2 100644 --- a/webrtc/sendonly/webrtc-unidirectional-h264.c +++ b/webrtc/sendonly/webrtc-unidirectional-h264.c @@ -196,6 +196,7 @@ create_receiver_entry (SoupWebsocketConnection * connection) g_assert (transceivers != NULL && transceivers->len > 0); trans = g_array_index (transceivers, GstWebRTCRTPTransceiver *, 0); trans->direction = GST_WEBRTC_RTP_TRANSCEIVER_DIRECTION_SENDONLY; + g_array_unref (transceivers); g_signal_connect (receiver_entry->webrtcbin, "on-negotiation-needed", G_CALLBACK (on_negotiation_needed_cb), (gpointer) receiver_entry);