# HG changeset patch # User Edgar Simo # Date 1249489909 0 # Node ID aa8de4b807728f54047388b3156a38e3ad13997e # Parent cf1ec33ae0563a8d3474adf21557ab04e4e81e52 Patch by Janosch Gräf I just noticed that there are rarely error messages and added some. diff -r cf1ec33ae056 -r aa8de4b80772 src/haptic/SDL_haptic.c --- a/src/haptic/SDL_haptic.c Wed Aug 05 08:12:31 2009 +0000 +++ b/src/haptic/SDL_haptic.c Wed Aug 05 16:31:49 2009 +0000 @@ -263,11 +263,13 @@ /* Must be a valid joystick */ if (!SDL_PrivateJoystickValid(&joystick)) { + SDL_SetError("Haptic: Joystick isn't valid."); return NULL; } /* Joystick must be haptic */ if (SDL_SYS_JoystickIsHaptic(joystick) <= 0) { + SDL_SetError("Haptic: Joystick isn't a haptic device."); return NULL; }