소스 검색

video/dummy: Don't zero out the fake display mode before adding it.

The SDL_zero call was in the wrong place as a historical accident, I think.
Ryan C. Gordon 4 년 전
부모
커밋
839387ed0a
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/video/dummy/SDL_nullvideo.c

+ 1 - 1
src/video/dummy/SDL_nullvideo.c

@@ -116,6 +116,7 @@ DUMMY_VideoInit(_THIS)
     SDL_DisplayMode mode;
 
     /* Use a fake 32-bpp desktop mode */
+    SDL_zero(mode);
     mode.format = SDL_PIXELFORMAT_RGB888;
     mode.w = 1024;
     mode.h = 768;
@@ -125,7 +126,6 @@ DUMMY_VideoInit(_THIS)
         return -1;
     }
 
-    SDL_zero(mode);
     SDL_AddDisplayMode(&_this->displays[0], &mode);
 
     /* We're done! */