From 6acfc5d1b3c55de4545cc8a749d0cb6552592624 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Wed, 24 Jan 2018 00:14:01 +0100 Subject: [PATCH] trezorhal: reply with winusb guid just for the main interface (0) --- winusb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/winusb.c b/winusb.c index 1f78f9a2c9..afdaf8b706 100644 --- a/winusb.c +++ b/winusb.c @@ -115,7 +115,8 @@ static int winusb_control_vendor_request(usbd_device *usbd_dev, status = USBD_REQ_HANDLED; } else if (((req->bmRequestType & USB_REQ_TYPE_RECIPIENT) == USB_REQ_TYPE_INTERFACE) && - (req->wIndex == WINUSB_REQ_GET_EXTENDED_PROPERTIES_OS_FEATURE_DESCRIPTOR)) { + (req->wIndex == WINUSB_REQ_GET_EXTENDED_PROPERTIES_OS_FEATURE_DESCRIPTOR) && + (usb_descriptor_index(req->wValue) == winusb_wcid.functions[0].bInterfaceNumber)) { *buf = (uint8_t*)(&guid); *len = MIN(*len, guid.header.dwLength);