Attachments you submit will be routed for moderation. If you have an account, please log in first.

Ticket #30: libusb-1.0.6-darwin-ppc-endian-fix.diff

File libusb-1.0.6-darwin-ppc-endian-fix.diff, 883 bytes (added by mk, 2 years ago)

Patch

  • libusb-1.0.6/libusb/os/darwin_usb.c

    old new  
    11911191  tpriv->req.bmRequestType     = setup->bmRequestType; 
    11921192  tpriv->req.bRequest          = setup->bRequest; 
    11931193  /* these values should already be in bus order */ 
    1194   tpriv->req.wValue            = setup->wValue; 
    1195   tpriv->req.wIndex            = setup->wIndex; 
    1196   tpriv->req.wLength           = setup->wLength; 
     1194  tpriv->req.wValue            = libusb_le16_to_cpu(setup->wValue); 
     1195  tpriv->req.wIndex            = libusb_le16_to_cpu(setup->wIndex); 
     1196  tpriv->req.wLength           = libusb_le16_to_cpu(setup->wLength); 
    11971197  /* data is stored after the libusb control block */ 
    11981198  tpriv->req.pData             = transfer->buffer + LIBUSB_CONTROL_SETUP_SIZE; 
    11991199  tpriv->req.completionTimeout = transfer->timeout;