mirror of
https://github.com/yawut/SDL.git
synced 2026-04-24 15:26:55 -05:00
Patch by Janosch Gräf <janosch.graef@gmx.net>
I just noticed that there are rarely error messages and added some.
This commit is contained in:
parent
1412877281
commit
2ca41a8224
|
|
@ -263,11 +263,13 @@ SDL_HapticOpenFromJoystick(SDL_Joystick * joystick)
|
|||
|
||||
/* 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;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user