Home | History | Annotate | Download | only in libusb
      1 diff --git a/libusb/os/darwin_usb.c b/libusb/os/darwin_usb.c
      2 index b0ee5b2..fe40899 100644
      3 --- a/libusb/os/darwin_usb.c
      4 +++ b/libusb/os/darwin_usb.c
      5 @@ -1449,8 +1449,14 @@ static int submit_bulk_transfer(struct usbi_transfer *itransfer) {
      6  
      7    cInterface = &priv->interfaces[iface];
      8  
      9 -  (*(cInterface->interface))->GetPipeProperties (cInterface->interface, pipeRef, &direction, &number,
     10 -                                                 &transferType, &maxPacketSize, &interval);
     11 +  ret = (*(cInterface->interface))->GetPipeProperties (cInterface->interface, pipeRef, &direction, &number,
     12 +                                                       &transferType, &maxPacketSize, &interval);
     13 +
     14 +  if (ret) {
     15 +    usbi_err (TRANSFER_CTX (transfer), "bulk transfer failed (dir = %s): %s (code = 0x%08x)", IS_XFERIN(transfer) ? "In" : "Out",
     16 +              darwin_error_str(ret), ret);
     17 +    return darwin_to_libusb (ret);
     18 +  }
     19  
     20    if (0 != (transfer->length % maxPacketSize)) {
     21      /* do not need a zero packet */
     22 
     23