From aae8d811d105fa5bb7a01de24a292b336827d21e Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sun, 25 Apr 2010 20:16:38 -0400 Subject: [PATCH] SDL-1.2: Quartz fullscreen video contentRect was used uninitialized. --- src/video/quartz/SDL_QuartzVideo.m | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/video/quartz/SDL_QuartzVideo.m b/src/video/quartz/SDL_QuartzVideo.m index 45929c9bd..d2d2169ff 100644 --- a/src/video/quartz/SDL_QuartzVideo.m +++ b/src/video/quartz/SDL_QuartzVideo.m @@ -479,6 +479,8 @@ static void QZ_UnsetVideoMode (_THIS, BOOL to_desktop) NSRect contentRect; CGDisplayFadeReservationToken fade_token = kCGDisplayFadeReservationInvalidToken; + contentRect = NSMakeRect (0, 0, width, height); + /* Fade to black to hide resolution-switching flicker (and garbage that is displayed by a destroyed OpenGL context, if applicable) */ if ( CGAcquireDisplayFadeReservation (5, &fade_token) == kCGErrorSuccess ) {