check_ms_os_desc: fix buffer overflow.

Bug: http://b/155505587
Test: check_ms_os_desc
Change-Id: Ie99715ab62571d24460c3a1fb859d22951f30cb8
This commit is contained in:
Josh Gao 2020-06-02 15:23:39 -07:00
parent 3f2f3bacf9
commit a2929d5751
1 changed files with 0 additions and 2 deletions

View File

@ -131,8 +131,6 @@ static void check_ms_os_desc_v1(libusb_device_handle* device_handle, const std::
errx(1, "failed to retrieve MS OS v1 compat descriptor: %s", libusb_error_name(rc));
}
memcpy(&hdr, data.data(), data.size());
struct __attribute__((packed)) ms_os_desc_v1_function {
uint8_t bFirstInterfaceNumber;
uint8_t reserved1;