src/video/cocoa/SDL_cocoamodes.m
changeset 6072 8b473f33c766
parent 6044 35448a5ea044
child 6101 4b88086910d3
equal deleted inserted replaced
6071:72f06ae88e7e 6072:8b473f33c766
   113 
   113 
   114 static SDL_bool
   114 static SDL_bool
   115 GetDisplayMode(_THIS, const void *moderef, SDL_DisplayMode *mode)
   115 GetDisplayMode(_THIS, const void *moderef, SDL_DisplayMode *mode)
   116 {
   116 {
   117     SDL_DisplayModeData *data;
   117     SDL_DisplayModeData *data;
   118     long width, height, bpp, refreshRate;
   118     long width = 0;
       
   119     long height = 0;
       
   120     long bpp = 0;
       
   121     long refreshRate = 0;
   119 
   122 
   120     data = (SDL_DisplayModeData *) SDL_malloc(sizeof(*data));
   123     data = (SDL_DisplayModeData *) SDL_malloc(sizeof(*data));
   121     if (!data) {
   124     if (!data) {
   122         return SDL_FALSE;
   125         return SDL_FALSE;
   123     }
   126     }