summaryrefslogtreecommitdiff
path: root/libusb/libusb.h
diff options
context:
space:
mode:
Diffstat (limited to 'libusb/libusb.h')
-rw-r--r--libusb/libusb.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/libusb/libusb.h b/libusb/libusb.h
index 1c3e9c8..0127d9f 100644
--- a/libusb/libusb.h
+++ b/libusb/libusb.h
@@ -24,7 +24,6 @@
#include <stdint.h>
#ifdef _MSC_VER
#define inline __inline
-#include <time.h>
#else
#include <sys/time.h>
#endif
@@ -659,9 +658,9 @@ enum libusb_error {
/** Other error */
LIBUSB_ERROR_OTHER = -99
-
- /* IMPORTANT: when adding new values to this enum, remember to update the
- libusb_strerror() function implementation! */
+
+ /* IMPORTANT: when adding new values to this enum, remember to
+ update the libusb_strerror() function implementation! */
};
/** \ingroup asyncio
@@ -1173,8 +1172,8 @@ static inline int libusb_get_descriptor(libusb_device_handle *dev,
uint8_t desc_type, uint8_t desc_index, unsigned char *data, int length)
{
return libusb_control_transfer(dev, LIBUSB_ENDPOINT_IN,
- LIBUSB_REQUEST_GET_DESCRIPTOR, (desc_type << 8) | desc_index, 0, data,
- (uint16_t) length, 1000);
+ LIBUSB_REQUEST_GET_DESCRIPTOR, (desc_type << 8) | desc_index,
+ 0, data, (uint16_t)length, 1000);
}
/** \ingroup desc
@@ -1195,7 +1194,8 @@ static inline int libusb_get_string_descriptor(libusb_device_handle *dev,
uint8_t desc_index, uint16_t langid, unsigned char *data, int length)
{
return libusb_control_transfer(dev, LIBUSB_ENDPOINT_IN,
- LIBUSB_REQUEST_GET_DESCRIPTOR, (LIBUSB_DT_STRING << 8) | desc_index,
+ LIBUSB_REQUEST_GET_DESCRIPTOR,
+ (uint16_t)((LIBUSB_DT_STRING << 8) | desc_index),
langid, data, (uint16_t)length, 1000);
}