From edb8ecdbf8fc171b11e0a27983e5af4a427315c0 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Wed, 3 Jan 2018 14:13:29 +0100 Subject: [PATCH] (xdk_joypad.c) Add C codepath for XGetDeviceChanges --- input/drivers_joypad/xdk_joypad.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/input/drivers_joypad/xdk_joypad.c b/input/drivers_joypad/xdk_joypad.c index e5f2fabab7..59482e814a 100644 --- a/input/drivers_joypad/xdk_joypad.c +++ b/input/drivers_joypad/xdk_joypad.c @@ -140,9 +140,15 @@ static void xdk_joypad_poll(void) #endif #if defined(_XBOX1) +#ifdef __cplusplus XGetDeviceChanges(XDEVICE_TYPE_GAMEPAD, reinterpret_cast(&dwInsertions), reinterpret_cast(&dwRemovals)); +#else + XGetDeviceChanges(XDEVICE_TYPE_GAMEPAD, + (PDWORD)&dwInsertions, + (PDWORD)&dwRemovals); +#endif #endif for (port = 0; port < MAX_PADS; port++)