From e6147fa55d55b0f018455573aa00bdf4f5d5bb69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20B=C3=ADlek?= Date: Sun, 3 Dec 2017 03:49:08 +0100 Subject: [PATCH] Using WINUSB_MS_VENDOR_CODE in extra string This might make some future debugging easier. --- src/winusb.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/winusb.c b/src/winusb.c index 38bf644..f009500 100644 --- a/src/winusb.c +++ b/src/winusb.c @@ -78,7 +78,8 @@ static void winusb_set_config(usbd_device* usbd_dev, uint16_t wValue) { } void winusb_setup(usbd_device* usbd_dev) { - usbd_register_extra_string(usbd_dev, 0xEE, "MSFT100!"); + static const char msft_extra_string[] = {'M', 'S', 'F', 'T', '1', '0', '0', WINUSB_MS_VENDOR_CODE, '\0'}; + usbd_register_extra_string(usbd_dev, 0xEE, msft_extra_string); usbd_register_set_config_callback(usbd_dev, winusb_set_config); /* Windows probes the compatible ID before setting the configuration,