timeoverlay: fix pad leak

Spotted by Jiri Uncovsky.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1336>
This commit is contained in:
Tim-Philipp Müller 2022-12-11 17:36:53 +00:00 committed by GStreamer Marge Bot
parent 20b207bf8f
commit b9d8fb3d63

View file

@ -386,6 +386,7 @@ gst_time_overlay_init (GstTimeOverlay * overlay)
video_sink = gst_element_get_static_pad (GST_ELEMENT (overlay), "video_sink");
overlay->orig_video_event = GST_PAD_EVENTFUNC (video_sink);
gst_pad_set_event_function (video_sink, gst_time_overlay_video_event);
gst_object_unref (video_sink);
}
static void