scratch_size was incorrectly passed as language ID when retrieving the language
ID table, this broke string retrieval on some devices. Submitted by: Hans Petter Selasky Reported by: Renato Botelho
This commit is contained in:
parent
8feb1ea45e
commit
c10e1453e7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=201680
@ -1691,8 +1691,7 @@ usb_alloc_device(device_t parent_dev, struct usb_bus *bus,
|
||||
udev->ddesc.iSerialNumber) {
|
||||
/* read out the language ID string */
|
||||
err = usbd_req_get_string_desc(udev, NULL,
|
||||
(char *)scratch_ptr, 4, scratch_size,
|
||||
USB_LANGUAGE_TABLE);
|
||||
(char *)scratch_ptr, 4, 0, USB_LANGUAGE_TABLE);
|
||||
} else {
|
||||
err = USB_ERR_INVAL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user