diff src/joystick/linux/SDL_sysjoystick.c @ 3590:493f252a455c

Fixed crash in joystick handling code. Newer 2.6 kernels add an additional 'resolution' field to input_absinfo. Note that we don't use that structure since we want to have enough space for the values even when building with an older kernel.
author Sam Lantinga <slouken@libsdl.org>
date Thu, 17 Dec 2009 07:22:48 +0000
parents c9dcc73f6a36
children f7b03b6838cb
line wrap: on
line diff
--- a/src/joystick/linux/SDL_sysjoystick.c	Thu Dec 17 06:08:20 2009 +0000
+++ b/src/joystick/linux/SDL_sysjoystick.c	Thu Dec 17 07:22:48 2009 +0000
@@ -701,7 +701,7 @@
                 continue;
             }
             if (test_bit(i, absbit)) {
-                int values[5];
+                int values[6];
 
                 if (ioctl(fd, EVIOCGABS(i), values) < 0)
                     continue;