Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@clifforous
Copy link
Contributor

@clifforous clifforous commented Feb 4, 2022

Fix for issue #334

@magnusja
Copy link
Owner

magnusja commented Feb 4, 2022

Seems to only be available in >1.0.25

Can we maybe use LIBUSB_API_VERSION to only do this for versions >1.0.25 (at compile time).

#if defined(LIBUSB_API_VERSION) && (LIBUSB_API_VERSION >= 0x01000109)
// do the setoption
 #endif

@clifforous
Copy link
Contributor Author

I found in 1.0.24 the option was named LIBUSB_OPTION_WEAK_AUTHORITY which still exists in 1.0.25 it is now just an alias of LIBUSB_OPTION_NO_DEVICE_DISCOVERY. So I targeted 0x01000108 with the old name and tested it works with both versions.

I tried 1.0.23 but I think versions <= 1.0.23 won't compile because of the file renaming fix 0a79ff0#diff-259bbe82c74cbf397987694efd5f89625a25ec45ff801d7d5206885d3092ce78

@magnusja
Copy link
Owner

magnusja commented Feb 5, 2022

Thanks a lot!!

@magnusja magnusja merged commit 2ff2310 into magnusja:develop Feb 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants