libusb-1.0.22 deprecated libusb_set_debug() with libusb_set_option()
This avoids the following compiler warnings when using more recent
versions of libusb:
src/libosmo-fl2k.c:384:2: warning: ‘libusb_set_debug’ is deprecated: Use libusb_set_option instead [-Wdeprecated-declarations]
libusb_set_debug(dev->ctx, 3);
^~~~~~~~~~~~~~~~
Details can be found at 539f22e2fd
This commit is contained in:
parent
d5c4dcc597
commit
79908e1109
|
@ -381,7 +381,11 @@ int fl2k_open(fl2k_dev_t **out_dev, uint32_t index)
|
|||
return -1;
|
||||
}
|
||||
|
||||
#if LIBUSB_API_VERSION >= 0x01000106
|
||||
libusb_set_option(dev->ctx, LIBUSB_OPTION_LOG_LEVEL, 3);
|
||||
#else
|
||||
libusb_set_debug(dev->ctx, 3);
|
||||
#endif
|
||||
|
||||
dev->dev_lost = 1;
|
||||
|
||||
|
|
Loading…
Reference in New Issue