From 639b39c46cda7b05c06145b3f0f7f8e1ba2d028e Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Wed, 15 Oct 2014 09:09:57 -0700 Subject: [PATCH] Fixed crash if the event subsystem didn't initialize properly --- src/core/linux/SDL_evdev.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/core/linux/SDL_evdev.c b/src/core/linux/SDL_evdev.c index 19333f2576cde..c4a7d05ce2fd3 100644 --- a/src/core/linux/SDL_evdev.c +++ b/src/core/linux/SDL_evdev.c @@ -584,6 +584,10 @@ SDL_EVDEV_Poll(void) Uint32 kval; #endif + if (!_this) { + return; + } + #if SDL_USE_LIBUDEV SDL_UDEV_Poll(); #endif