X11: Fixed SDL_GL_GetSwapInterval() returning -1 if interval is unknown.
authorPhilipp Wiesemann <philipp.wiesemann@arcor.de>
Wed, 11 May 2016 21:11:12 +0200
changeset 10170ccdb4d0934e9
parent 10169 e8062c7fa8b8
child 10171 5b61e12c0a30
X11: Fixed SDL_GL_GetSwapInterval() returning -1 if interval is unknown.

It should return 0 as a safe default if the interval can not be determined.
src/video/x11/SDL_x11opengl.c
     1.1 --- a/src/video/x11/SDL_x11opengl.c	Wed May 11 21:10:41 2016 +0200
     1.2 +++ b/src/video/x11/SDL_x11opengl.c	Wed May 11 21:11:12 2016 +0200
     1.3 @@ -710,7 +710,7 @@
     1.4     with 0 as an argument.
     1.5  */
     1.6  
     1.7 -static int swapinterval = -1;
     1.8 +static int swapinterval = 0;
     1.9  int
    1.10  X11_GL_SetSwapInterval(_THIS, int interval)
    1.11  {