mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-13 09:55:42 +00:00
x11: Explicitly specify EGL platform
Mesa's eglGetDisplay() chooses the native EGL platform from EGL_PLATFORM, limited autodetection, or the build-time default. If that selects Wayland while SDL is using the X11 video backend, Mesa can treat the X11 Display pointer as a wl_display and crash during eglInitialize(). See: https://gitlab.com/qemu-project/qemu/-/work_items/3540
This commit is contained in:
parent
a0c31c3afc
commit
b3aa7083e2
1 changed files with 2 additions and 1 deletions
|
|
@ -53,7 +53,8 @@ int X11_GLES_LoadLibrary(_THIS, const char *path)
|
|||
#endif
|
||||
}
|
||||
|
||||
return SDL_EGL_LoadLibrary(_this, path, (NativeDisplayType) data->display, 0);
|
||||
return SDL_EGL_LoadLibrary(_this, path, (NativeDisplayType) data->display,
|
||||
EGL_PLATFORM_X11_KHR);
|
||||
}
|
||||
|
||||
XVisualInfo *X11_GLES_GetVisual(_THIS, Display *display, int screen)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue