Skip to content
Permalink
Browse files

Another fix to prevent dereferencing a null window pointer in SDL_mou…

…se.c
  • Loading branch information
gabomdq committed Jun 28, 2014
1 parent a9bb889 commit 9dc2614e7d2df4e5387316f34fa53d0c49a24a83
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/events/SDL_mouse.c
@@ -248,7 +248,7 @@ SDL_PrivateSendMouseMotion(SDL_Window * window, SDL_MouseID mouseID, int relativ

/* make sure that the pointers find themselves inside the windows,
unless we have the mouse captured. */
if ((window->flags & SDL_WINDOW_MOUSE_CAPTURE) == 0) {
if (window != NULL && ((window->flags & SDL_WINDOW_MOUSE_CAPTURE) == 0)) {
int x_max = 0, y_max = 0;

// !!! FIXME: shouldn't this be (window) instead of (mouse->focus)?

0 comments on commit 9dc2614

Please sign in to comment.