glimagesink: memory leaks in 1.19.3
The following pipeline will leak about ~8MB per iteration. Tested on the 1.19.3. The memory leak is much smaller on 1.18.5. The ximagesink will not leak.
for (int i = 0; i < 100; ++i) {
GstElement* pipe = gst_parse_launch("videotestsrc is-live=true ! video/x-raw,width=1920,height=1080,framerate=30/1 ! glsinkbin sink=glimagesink", nullptr);
//GstElement* pipe = gst_parse_launch("videotestsrc is-live=true ! video/x-raw,width=1920,height=1080,framerate=30/1 ! ximagesink", nullptr); //NO MEMLEAK
gst_element_set_state(pipe, GST_STATE_PLAYING);
std::this_thread::sleep_for(std::chrono::milliseconds(100));
gst_element_set_state(pipe, GST_STATE_NULL);
gst_object_unref(pipe);
}