summaryrefslogtreecommitdiff
path: root/spectro/usbio_nt.c
diff options
context:
space:
mode:
Diffstat (limited to 'spectro/usbio_nt.c')
-rwxr-xr-x[-rw-r--r--]spectro/usbio_nt.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/spectro/usbio_nt.c b/spectro/usbio_nt.c
index 34426fd..f3748bb 100644..100755
--- a/spectro/usbio_nt.c
+++ b/spectro/usbio_nt.c
@@ -589,6 +589,9 @@ static int icoms_usb_transaction(
a1logd(p->log, 8, "icoms_usb_transaction: req type 0x%x ep 0x%x size %d\n",ttype,endpoint,length);
+ if (transferred != NULL)
+ *transferred = 0;
+
if (ttype != icom_usb_trantype_interrutpt
&& ttype != icom_usb_trantype_bulk) {
/* We only handle interrupt & bulk, not control */
@@ -692,6 +695,9 @@ int timeout) {
a1logd(p->log, 8, "icoms_usb_control_msg: type 0x%x req 0x%x size %d\n",requesttype,request,size);
+ if (transferred != NULL)
+ *transferred = 0;
+
memset(&req, 0, sizeof(libusb_request));
req.timeout = timeout;