mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 16:50:47 +00:00
gl/wayland: call eglTerminate() before wl_display_disconnect()
Calling these two functions in the wrong order will result in use-after-free inside wayland. https://bugzilla.gnome.org/show_bug.cgi?id=787293
This commit is contained in:
parent
143f9abf49
commit
a5aff145a2
1 changed files with 4 additions and 0 deletions
|
@ -91,6 +91,10 @@ gst_gl_display_wayland_finalize (GObject * object)
|
|||
{
|
||||
GstGLDisplayWayland *display_wayland = GST_GL_DISPLAY_WAYLAND (object);
|
||||
|
||||
/* Cause eglTerminate() to occur before wl_display_disconnect()
|
||||
* https://bugzilla.gnome.org/show_bug.cgi?id=787293 */
|
||||
g_object_set_data (object, "gst.gl.display.egl", NULL);
|
||||
|
||||
if (!display_wayland->foreign_display && display_wayland->display) {
|
||||
wl_display_flush (display_wayland->display);
|
||||
wl_display_disconnect (display_wayland->display);
|
||||
|
|
Loading…
Reference in a new issue