tests/webrtc: fix a data channel leak in a test

test_data_channel_create_after_negotiate overrides the data_channel_data
without ever freeing it.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1240>
This commit is contained in:
Matthew Waters 2020-05-05 17:15:51 +10:00 committed by GStreamer Merge Bot
parent d552c6556c
commit d0be6b74f2

View file

@ -1781,6 +1781,7 @@ have_data_channel_create_data_channel (struct test_webrtc *t,
&another);
g_assert_nonnull (another);
t->data_channel_data = another;
t->data_channel_notify = (GDestroyNotify) g_object_unref;
g_signal_connect (another, "on-error",
G_CALLBACK (on_channel_error_not_reached), NULL);
}