diff options
| author | heyuanjie87 <[email protected]> | 2013-01-17 14:03:45 +0800 |
|---|---|---|
| committer | heyuanjie87 <[email protected]> | 2013-01-17 14:03:45 +0800 |
| commit | 7ce0547575e11cb9ce94f86fcce3709d060dcc00 (patch) | |
| tree | 6ace46193491b7241ca930460bc1a75f87172728 | |
| parent | a3bde3c4a364a2648f626eaab6b79f6e74535525 (diff) | |
fixed the string descriptor send to host more than actual
| -rw-r--r-- | components/drivers/usb/usbdevice/core/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/components/drivers/usb/usbdevice/core/core.c b/components/drivers/usb/usbdevice/core/core.c index ea4efde2d7..9f1738ed33 100644 --- a/components/drivers/usb/usbdevice/core/core.c +++ b/components/drivers/usb/usbdevice/core/core.c @@ -124,7 +124,7 @@ static rt_err_t _get_string_descriptor(struct udevice* device, ureq_t setup) } } - if(setup->length == 0xFF) + if(setup->length > len) len = str_desc.bLength; else len = setup->length; |
