You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit was created on GitHub.com and signed with GitHub’s verified signature.
Other
Fix string descriptors with trailing junk and harden string reads
Fixed
String descriptors end at the first NUL character. Some devices (an
FT2232D clone here) declare a longer descriptor holding a NUL-terminated
string followed by leftover EEPROM bytes, which came back as garbage
appended to the serial number; Linux cuts at the NUL too.
String reads follow the Linux kernel's recovery: if a device stalls the
full-size request or answers it short, the 2-byte header is read and then
exactly the declared length. A malformed or empty language table falls
back to US English, and the language is read once per handle instead of
before every string.
The hardware tests no longer probe a nonexistent string index on every
attached device: some FTDI clones stall all requests after that until
they are reset. The check now runs only on the nominated bulk-IN device.