Marcus von Appen fixed bug 1530: X11 touch initialisation does not check its file handles
authorSam Lantinga <slouken@libsdl.org>
Mon, 02 Jul 2012 08:33:10 -0400
changeset 6348 049721824c2e
parent 6346 56871d364efc
child 6349 bc8de0568373
Marcus von Appen fixed bug 1530: X11 touch initialisation does not check its file handles
src/video/x11/SDL_x11touch.c
--- a/src/video/x11/SDL_x11touch.c	Mon Jun 25 11:10:34 2012 -0400
+++ b/src/video/x11/SDL_x11touch.c	Mon Jul 02 08:33:10 2012 -0400
@@ -46,6 +46,7 @@
 #ifdef SDL_INPUT_LINUXEV
     FILE *fd;
     fd = fopen("/proc/bus/input/devices","r");
+    if (!fd) return;
 
     int i = 0;
     int tsfd;