mirror of
https://github.com/Lime3DS/Lime3DS
synced 2024-12-26 09:02:44 -06:00
sdl: Exit if SDL fails to create software renderer (#6430)
This commit is contained in:
parent
26d6f9d1c6
commit
3dd6557332
1 changed files with 5 additions and 0 deletions
|
@ -37,6 +37,11 @@ EmuWindow_SDL2_SW::EmuWindow_SDL2_SW(bool fullscreen, bool is_secondary)
|
|||
window_surface = SDL_GetWindowSurface(render_window);
|
||||
renderer = SDL_CreateSoftwareRenderer(window_surface);
|
||||
|
||||
if (renderer == nullptr) {
|
||||
LOG_CRITICAL(Frontend, "Failed to create SDL2 software renderer: {}", SDL_GetError());
|
||||
exit(1);
|
||||
}
|
||||
|
||||
if (fullscreen) {
|
||||
Fullscreen();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue