From f5ea4a0c65edbf83b15e699524db8f8462ced776 Mon Sep 17 00:00:00 2001 From: Brad Parker Date: Tue, 5 Dec 2017 17:19:17 -0500 Subject: [PATCH] dinput: add missing function parameter --- input/drivers_joypad/dinput_joypad.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/input/drivers_joypad/dinput_joypad.c b/input/drivers_joypad/dinput_joypad.c index b390e315cf..1a9f6325eb 100644 --- a/input/drivers_joypad/dinput_joypad.c +++ b/input/drivers_joypad/dinput_joypad.c @@ -63,7 +63,7 @@ extern bool g_xinput_block_pads; extern int g_xinput_pad_indexes[MAX_USERS]; extern LPDIRECTINPUT8 g_dinput_ctx; -bool dinput_joypad_get_vidpid_from_xinput_index(int index, int *vid, int *pid) +bool dinput_joypad_get_vidpid_from_xinput_index(int index, int *vid, int *pid, int *dinput_index) { int i; @@ -79,6 +79,9 @@ bool dinput_joypad_get_vidpid_from_xinput_index(int index, int *vid, int *pid) if (pid) *pid = g_pads[i].pid; + if (dinput_index) + *dinput_index = i; + return true; } }