From 5e74299a833e753a739804b65ef577d87371260e Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sun, 20 Oct 2013 15:40:20 -0400 Subject: [PATCH] Fix adding of XInput devices (thanks, Mitchell!) Partially fixes Bugzilla #2126. --- src/joystick/windows/SDL_dxjoystick.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/joystick/windows/SDL_dxjoystick.c b/src/joystick/windows/SDL_dxjoystick.c index 69393279e3148..d8149a301c6d5 100644 --- a/src/joystick/windows/SDL_dxjoystick.c +++ b/src/joystick/windows/SDL_dxjoystick.c @@ -733,11 +733,11 @@ AddXInputDevice(const Uint8 userid, JoyStick_DeviceData **pContext) pNewJoystick->pNext = SYS_Joystick; SYS_Joystick = pNewJoystick; + return; /* already in the list. */ } pPrevJoystick = pNewJoystick; pNewJoystick = pNewJoystick->pNext; - return; /* already in the list. */ } pNewJoystick = (JoyStick_DeviceData *) SDL_malloc(sizeof (JoyStick_DeviceData));