Skip to content

Commit

Permalink
[fix] ffi/SDL2: crash with SDL_FULLSCREEN (#900)
Browse files Browse the repository at this point in the history
Only actively used on device ports (Ubuntu Touch, Sailfish), so it was silently broken.

Cf. koreader/koreader#4960 and #899
  • Loading branch information
Frenzie committed Apr 22, 2019
1 parent 4c2ed56 commit 5be7118
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ffi/SDL2_0.lua
Expand Up @@ -77,7 +77,7 @@ function S.open()

local full_screen = os.getenv("SDL_FULLSCREEN")
if full_screen then
local mode = ffi.new("struct SDL_DisplayMode")
local mode = ffi.new("SDL_DisplayMode")
if SDL.SDL_GetCurrentDisplayMode(0, mode) ~= 0 then
error("SDL cannot get current display mode.")
end
Expand Down

0 comments on commit 5be7118

Please sign in to comment.