diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2021-05-13 18:23:50 +0100 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2021-05-13 18:23:50 +0100 |
commit | b3d6928f3593796e491ce4f28278184b6130c3c5 (patch) | |
tree | 5e9bd95373ad6bead21cd8c9374476cb0a31d774 /gdk | |
parent | 3d8ba93f59e82378217e9e433b5b5b3814b784c8 (diff) | |
download | gtk+-b3d6928f3593796e491ce4f28278184b6130c3c5.tar.gz |
x11: Pair eglInitialize with eglTerminate
If we bail out after EGL initialization we want to go back to a stable
state and not leave EGL hanging.
Diffstat (limited to 'gdk')
-rw-r--r-- | gdk/x11/gdkglcontext-egl.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/gdk/x11/gdkglcontext-egl.c b/gdk/x11/gdkglcontext-egl.c index cab476232f..08f4493a8b 100644 --- a/gdk/x11/gdkglcontext-egl.c +++ b/gdk/x11/gdkglcontext-egl.c @@ -596,7 +596,10 @@ gdk_x11_screen_init_egl (GdkX11Screen *screen) */ const char *vendor = eglQueryString (edpy, EGL_VENDOR); if (strstr (vendor, "NVIDIA") != NULL) - return FALSE; + { + eglTerminate (edpy); + return FALSE; + } display_x11->have_egl = TRUE; display_x11->egl_version = epoxy_egl_version (dpy); |