Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Fixed operator precedence
Browse files Browse the repository at this point in the history
Frank Zago to SDL

& takes precedence over |. (was a gcc warning)
  • Loading branch information
slouken committed Mar 12, 2011
1 parent 2cb4972 commit 99c2a05
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/video/SDL_video.c
Expand Up @@ -1885,7 +1885,7 @@ SDL_OnWindowFocusGained(SDL_Window * window)
_this->SetWindowGammaRamp(_this, window, window->gamma);
}

if ((window->flags & SDL_WINDOW_INPUT_GRABBED | SDL_WINDOW_FULLSCREEN) &&
if ((window->flags & (SDL_WINDOW_INPUT_GRABBED | SDL_WINDOW_FULLSCREEN)) &&
_this->SetWindowGrab) {
_this->SetWindowGrab(_this, window);
}
Expand All @@ -1898,7 +1898,7 @@ SDL_OnWindowFocusLost(SDL_Window * window)
_this->SetWindowGammaRamp(_this, window, window->saved_gamma);
}

if ((window->flags & SDL_WINDOW_INPUT_GRABBED | SDL_WINDOW_FULLSCREEN) &&
if ((window->flags & (SDL_WINDOW_INPUT_GRABBED | SDL_WINDOW_FULLSCREEN)) &&
_this->SetWindowGrab) {
_this->SetWindowGrab(_this, window);
}
Expand Down

0 comments on commit 99c2a05

Please sign in to comment.