Skip to content

Commit

Permalink
Fixed duplicate controller entries on Mac OS X when using libusb, due…
Browse files Browse the repository at this point in the history
… to the HID interface number not being available in the Mac OS X HID code.
  • Loading branch information
slouken committed Dec 21, 2019
1 parent 46e1377 commit 868551b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hidapi/SDL_hidapi.c
Expand Up @@ -559,7 +559,7 @@ struct hid_device_info HID_API_EXPORT * HID_API_CALL hid_enumerate(unsigned shor
for (raw_dev = raw_devs; raw_dev; raw_dev = raw_dev->next) {
if (usb_dev->vendor_id == raw_dev->vendor_id &&
usb_dev->product_id == raw_dev->product_id &&
usb_dev->interface_number == raw_dev->interface_number) {
(raw_dev->interface_number < 0 || usb_dev->interface_number == raw_dev->interface_number)) {
bFound = SDL_TRUE;
break;
}
Expand Down

0 comments on commit 868551b

Please sign in to comment.