Explorar o código

Static analysis fix: uninitialized data.

(This is Clang not knowing that SDL_SetError() always returns -1.)
Ryan C. Gordon %!s(int64=11) %!d(string=hai) anos
pai
achega
3aae0ed2c5
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      src/video/SDL_video.c

+ 2 - 0
src/video/SDL_video.c

@@ -1128,6 +1128,8 @@ SDL_UpdateFullscreenMode(SDL_Window * window, SDL_bool fullscreen)
         if (setDisplayMode) {
             SDL_DisplayMode fullscreen_mode;
 
+            SDL_zero(fullscreen_mode);
+
             if (SDL_GetWindowDisplayMode(other, &fullscreen_mode) == 0) {
                 SDL_bool resized = SDL_TRUE;