mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-07 07:00:48 +00:00
x11: Check for a valid video device pointer before dereferencing the name
This commit is contained in:
parent
bad5dced3e
commit
95c0b49de0
1 changed files with 1 additions and 1 deletions
|
|
@ -307,7 +307,7 @@ static bool X11_ShowMessageBoxImpl(const SDL_MessageBoxData *messageboxdata, int
|
|||
}
|
||||
|
||||
/* Create window */
|
||||
if (messageboxdata->window && SDL_strcmp(video->name, "x11") == 0) {
|
||||
if (messageboxdata->window && video && SDL_strcmp(video->name, "x11") == 0) {
|
||||
// Only use the window as a parent if it is from the X11 driver.
|
||||
parent_window = messageboxdata->window;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue