From 0a833bc41750bded7d7f182efd564ef8fff6b67f Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Mon, 11 Feb 2013 15:21:00 +0000 Subject: [PATCH] Linux: Don't set the USBFS_URB_SHORT_NOT_OK flag on the last urb * Closes #142 --- libusb/os/linux_usbfs.c | 2 +- libusb/version_nano.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libusb/os/linux_usbfs.c b/libusb/os/linux_usbfs.c index 3d79bb1..ce77229 100644 --- a/libusb/os/linux_usbfs.c +++ b/libusb/os/linux_usbfs.c @@ -1754,7 +1754,7 @@ static int submit_bulk_transfer(struct usbi_transfer *itransfer, urb->type = urb_type; urb->endpoint = transfer->endpoint; urb->buffer = transfer->buffer + (i * bulk_buffer_len); - if (use_bulk_continuation && !is_out) + if (use_bulk_continuation && !is_out && (i != num_urbs - 1)) urb->flags = USBFS_URB_SHORT_NOT_OK; if (i == num_urbs - 1 && last_urb_partial) urb->buffer_length = transfer->length % bulk_buffer_len; diff --git a/libusb/version_nano.h b/libusb/version_nano.h index 44e6d46..cd49855 100644 --- a/libusb/version_nano.h +++ b/libusb/version_nano.h @@ -1 +1 @@ -#define LIBUSB_NANO 10602 +#define LIBUSB_NANO 10603 -- 2.11.4.GIT