diff src/video/SDL_renderer_gl.c @ 1928:861bc36f0ab3

Fixed crash with multiple windows
author Sam Lantinga <slouken@libsdl.org>
date Sun, 23 Jul 2006 00:19:12 +0000
parents aeb8263d377a
children 420716272158
line wrap: on
line diff
--- a/src/video/SDL_renderer_gl.c	Sat Jul 22 23:04:41 2006 +0000
+++ b/src/video/SDL_renderer_gl.c	Sun Jul 23 00:19:12 2006 +0000
@@ -199,8 +199,7 @@
     GL_RenderData *data;
 
     if (!(window->flags & SDL_WINDOW_OPENGL)) {
-        window->flags |= SDL_WINDOW_OPENGL;
-        if (SDL_RecreateWindow(window) < 0) {
+        if (SDL_RecreateWindow(window, window->flags | SDL_WINDOW_OPENGL) < 0) {
             return NULL;
         }
     }