Fixed crash in SDL_SetGammaRamp()

--HG--
branch : SDL-1.2
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/branches/SDL-1.2%402712
This commit is contained in:
Sam Lantinga 2008-01-25 05:48:08 +00:00
parent a09301c4f1
commit f3adfbb15c

View file

@ -784,9 +784,11 @@ SDL_Surface *DIB_SetVideoMode(_THIS, SDL_Surface *current,
if ( screen_pal && (flags & (SDL_FULLSCREEN|SDL_HWPALETTE)) ) { if ( screen_pal && (flags & (SDL_FULLSCREEN|SDL_HWPALETTE)) ) {
grab_palette = TRUE; grab_palette = TRUE;
} }
if ( screen_pal ) {
/* BitBlt() maps colors for us */ /* BitBlt() maps colors for us */
video->flags |= SDL_HWPALETTE; video->flags |= SDL_HWPALETTE;
} }
}
#ifndef _WIN32_WCE #ifndef _WIN32_WCE
/* Resize the window */ /* Resize the window */
if ( !SDL_windowid && !IsZoomed(SDL_Window) ) { if ( !SDL_windowid && !IsZoomed(SDL_Window) ) {