This commit is contained in:
twinaphex 2020-08-28 19:59:31 +02:00
parent ace0e3eb90
commit 88a93b0053
2 changed files with 4 additions and 3 deletions

View File

@ -57,8 +57,8 @@ static BOOL CALLBACK enum_joypad_cb(const DIDEVICEINSTANCE *inst, void *p)
if (FAILED(IDirectInput8_CreateDevice(
g_dinput_ctx, inst->guidInstance, pad, NULL)))
#else
if (FAILED(IDirectInput8_CreateDevice(
g_dinput_ctx, &inst->guidInstance, pad, NULL)))
if (FAILED(IDirectInput8_CreateDevice(
g_dinput_ctx, &inst->guidInstance, pad, NULL)))
#endif
return DIENUM_CONTINUE;

View File

@ -175,7 +175,8 @@ static int udev_add_pad(struct udev_device *dev, unsigned p, int fd, const char
pad->vid = pad->pid = 0;
if (ioctl(fd, EVIOCGID, &inputid) >= 0) {
if (ioctl(fd, EVIOCGID, &inputid) >= 0)
{
pad->vid = inputid.vendor;
pad->pid = inputid.product;
}