Skip to content
This repository was archived by the owner on Feb 26, 2020. It is now read-only.

Commit 0cbc3a4

Browse files
blabbersignal11
authored andcommitted
libusb: Adapt to FreeBSD 10
FreeBSD 10 has libusb_get_string_descriptor() in base libusb, so don't define it here.
1 parent 417b2bf commit 0cbc3a4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

libusb/hid.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -313,9 +313,9 @@ static int get_usage(uint8_t *report_descriptor, size_t size,
313313
}
314314
#endif /* INVASIVE_GET_USAGE */
315315

316-
#ifdef __FreeBSD__
317-
/* The FreeBSD version of libusb doesn't have this funciton. In mainline
318-
libusb, it's inlined in libusb.h. This function will bear a striking
316+
#if defined(__FreeBSD__) && __FreeBSD__ < 10
317+
/* The libusb version included in FreeBSD < 10 doesn't have this function. In
318+
mainline libusb, it's inlined in libusb.h. This function will bear a striking
319319
resemblence to that one, because there's about one way to code it.
320320
321321
Note that the data parameter is Unicode in UTF-16LE encoding.

0 commit comments

Comments
 (0)