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

Commit

Permalink
Linux: Search a smaller set of potential joystick axes.
Browse files Browse the repository at this point in the history
Newer kernels seem to report bogus axes in the higher ranges, for example
 with a standard PlayStation 3 controller plugged in via USB.
  • Loading branch information
icculus committed Jul 14, 2011
1 parent 861a888 commit d4dc53c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/joystick/linux/SDL_sysjoystick.c
Expand Up @@ -703,7 +703,7 @@ EV_ConfigJoystick(SDL_Joystick * joystick, int fd)
++joystick->nbuttons;
}
}
for (i = 0; i < ABS_MAX; ++i) {
for (i = 0; i < ABS_MISC; ++i) {
/* Skip hats */
if (i == ABS_HAT0X) {
i = ABS_HAT3Y;
Expand Down

0 comments on commit d4dc53c

Please sign in to comment.