Fixed bug 1605 - SDL_DestroyWindow causes erroneous error message
authorSam Lantinga
Fri, 28 Sep 2012 04:03:06 -0700
changeset 6496d7cb947898d7
parent 6495 2bf42c5e897a
child 6497 e844e2632149
Fixed bug 1605 - SDL_DestroyWindow causes erroneous error message

You can't pass a NULL window into SDL_GL_MakeCurrent()
src/video/SDL_video.c
     1.1 --- a/src/video/SDL_video.c	Fri Sep 28 03:54:39 2012 -0700
     1.2 +++ b/src/video/SDL_video.c	Fri Sep 28 04:03:06 2012 -0700
     1.3 @@ -1978,7 +1978,7 @@
     1.4      /* make no context current if this is the current context window. */
     1.5      if (window->flags & SDL_WINDOW_OPENGL) {
     1.6          if (_this->current_glwin == window) {
     1.7 -            SDL_GL_MakeCurrent(NULL, NULL);
     1.8 +            SDL_GL_MakeCurrent(window, NULL);
     1.9          }
    1.10      }
    1.11