Commit 68ece95c authored by Ludovic Rousseau's avatar Ludovic Rousseau

InterruptStop(): Log the libusb text instead of number

If libusb_cancel_transfer() fails we now use libusb_error_name() to get the
error message in text instead of just the error number.

The log message is now
00000008 ccid_usb.c:1399:InterruptStop() libusb_cancel_transfer failed: LIBUSB_ERROR_NOT_FOUND
instead of:
00000007 ccid_usb.c:1399:InterruptStop() libusb_cancel_transfer failed: -5
parent 6d2bebcc
......@@ -1396,7 +1396,8 @@ void InterruptStop(int reader_index)
ret = libusb_cancel_transfer(transfer);
if (ret < 0)
DEBUG_CRITICAL2("libusb_cancel_transfer failed: %d", ret);
DEBUG_CRITICAL2("libusb_cancel_transfer failed: %s",
} /* InterruptStop */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment