From 8fe38afd2b335831a5659e5ef44254fde769c727 Mon Sep 17 00:00:00 2001 From: xdavidwu Date: Thu, 16 Jan 2020 04:16:53 +0800 Subject: Fix: [SDL2] Correct name of the video driver in debug log SDL_GetVideoDriver(0) returns name of first video driver included in the library, not the driver currently used. SDL_GetCurrentVideoDriver() does what we want here. --- src/video/sdl2_v.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video/sdl2_v.cpp b/src/video/sdl2_v.cpp index 9ae8c3ca2..0b3b9b8e3 100644 --- a/src/video/sdl2_v.cpp +++ b/src/video/sdl2_v.cpp @@ -647,7 +647,7 @@ const char *VideoDriver_SDL::Start(const char * const *parm) return SDL_GetError(); } - const char *dname = SDL_GetVideoDriver(0); + const char *dname = SDL_GetCurrentVideoDriver(); DEBUG(driver, 1, "SDL2: using driver '%s'", dname); MarkWholeScreenDirty(); -- cgit v1.2.3-70-g09d2