am c672cb07: Merge "Include the error code if GetPipeProperties fails."

* commit 'c672cb07431c66e80a4e1b8845f25a7abb0bac9b':
  Include the error code if GetPipeProperties fails.
This commit is contained in:
Elliott Hughes 2015-08-06 17:58:07 +00:00 committed by Android Git Automerger
commit 2fbae4829b
2 changed files with 6 additions and 2 deletions

View file

@ -34,6 +34,10 @@
#define DBG D #define DBG D
// There's no strerror equivalent for the errors returned by IOKit.
// https://developer.apple.com/library/mac/documentation/DeviceDrivers/Conceptual/AccessingHardware/AH_Handling_Errors/AH_Handling_Errors.html
// Search the web for "IOReturn.h" to find a complete up to date list.
static IONotificationPortRef notificationPort = 0; static IONotificationPortRef notificationPort = 0;
static io_iterator_t notificationIterator; static io_iterator_t notificationIterator;
@ -362,7 +366,7 @@ CheckInterface(IOUSBInterfaceInterface **interface, UInt16 vendor, UInt16 produc
handle->zero_mask = maxPacketSize - 1; handle->zero_mask = maxPacketSize - 1;
} else { } else {
DBG("ERR: FindDeviceInterface - could not get pipe properties\n"); DBG("ERR: FindDeviceInterface - could not get pipe properties (%08x)\n", kr);
goto err_get_pipe_props; goto err_get_pipe_props;
} }
} }

View file

@ -210,7 +210,7 @@ static int try_interfaces(IOUSBDeviceInterface182 **dev, usb_handle *handle) {
handle->zero_mask = maxPacketSize - 1; handle->zero_mask = maxPacketSize - 1;
} }
} else { } else {
ERR("could not get pipe properties\n"); ERR("could not get pipe properties (%08x)\n", kr);
} }
if (handle->info.has_bulk_in && handle->info.has_bulk_out) { if (handle->info.has_bulk_in && handle->info.has_bulk_out) {