diff --git a/src/video/kmsdrm/SDL_kmsdrmopengles.c b/src/video/kmsdrm/SDL_kmsdrmopengles.c index 75c87f343..ae4b3580b 100644 --- a/src/video/kmsdrm/SDL_kmsdrmopengles.c +++ b/src/video/kmsdrm/SDL_kmsdrmopengles.c @@ -37,7 +37,8 @@ int KMSDRM_GLES_LoadLibrary(_THIS, const char *path) { - return SDL_EGL_LoadLibrary(_this, path, ((SDL_VideoData *)_this->driverdata)->gbm, EGL_PLATFORM_GBM_MESA); + NativeDisplayType display = (NativeDisplayType)((SDL_VideoData *)_this->driverdata)->gbm; + return SDL_EGL_LoadLibrary(_this, path, display, EGL_PLATFORM_GBM_MESA); } SDL_EGL_CreateContext_impl(KMSDRM) diff --git a/src/video/kmsdrm/SDL_kmsdrmvideo.c b/src/video/kmsdrm/SDL_kmsdrmvideo.c index 3c6b6922f..cbc1704a6 100644 --- a/src/video/kmsdrm/SDL_kmsdrmvideo.c +++ b/src/video/kmsdrm/SDL_kmsdrmvideo.c @@ -349,10 +349,9 @@ KMSDRM_WaitPageFlip(_THIS, SDL_WindowData *windata, int timeout) { /* SDL Video and Display initialization/handling functions */ /* _this is a SDL_VideoDevice * */ /*****************************************************************************/ -static int +static void KMSDRM_DestroySurfaces(_THIS, SDL_Window * window) { - SDL_VideoData *viddata = ((SDL_VideoData *)_this->driverdata); SDL_WindowData *windata = (SDL_WindowData *)window->driverdata; KMSDRM_WaitPageFlip(_this, windata, -1);