Skip to content

Commit

Permalink
Don't crash in WIN_GL_InitExtensions() if the OpenGL library couldn't…
Browse files Browse the repository at this point in the history
… be loaded
  • Loading branch information
slouken committed Apr 23, 2014
1 parent a5ce57b commit 3e3570d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/video/windows/SDL_windowsopengl.c
Expand Up @@ -334,6 +334,10 @@ WIN_GL_InitExtensions(_THIS)
HGLRC hglrc;
PIXELFORMATDESCRIPTOR pfd;

if (!_this->gl_data) {
return;
}

hwnd =
CreateWindow(SDL_Appname, SDL_Appname, (WS_POPUP | WS_DISABLED), 0, 0,
10, 10, NULL, NULL, SDL_Instance, NULL);
Expand Down

0 comments on commit 3e3570d

Please sign in to comment.