Browse Source

libusb_control_transfer 16 bit words are endian specific.

Con Kolivas 13 years ago
parent
commit
0a15beb742
1 changed files with 1 additions and 1 deletions
  1. 1 1
      usbutils.c

+ 1 - 1
usbutils.c

@@ -2071,7 +2071,7 @@ int _usb_transfer(struct cgpu_info *cgpu, uint8_t request_type, uint8_t bRequest
 
 	STATS_TIMEVAL(&tv_start);
 	err = libusb_control_transfer(usbdev->handle, request_type,
-		bRequest, wValue, wIndex, NULL, 0,
+		bRequest, htole16(wValue), htole16(wIndex), NULL, 0,
 		timeout == DEVTIMEOUT ? usbdev->found->timeout : timeout);
 	STATS_TIMEVAL(&tv_finish);
 	USB_STATS(cgpu, &tv_start, &tv_finish, err, cmd, SEQ0);