Skip to content

Commit 330e59f

Browse files
Michael Ammannbogdanm
authored andcommitted
make buffer big enough
1 parent d3963de commit 330e59f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

libraries/USBHost/USBHost/USBHost.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -852,7 +852,7 @@ USB_TYPE USBHost::enumerate(USBDeviceConnected * dev, IUSBEnumerator* pEnumerato
852852

853853
pEnumerator->setVidPid( data[8] | (data[9] << 8), data[10] | (data[11] << 8) );
854854

855-
res = getConfigurationDescriptor(dev, data, 300, &total_conf_descr_length);
855+
res = getConfigurationDescriptor(dev, data, sizeof(data), &total_conf_descr_length);
856856
if (res != USB_TYPE_OK) {
857857
usb_mutex.unlock();
858858
return res;

libraries/USBHost/USBHost/USBHost.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ class USBHost : public USBHALHost {
272272
Mutex td_mutex;
273273

274274
// buffer for conf descriptor
275-
uint8_t data[300];
275+
uint8_t data[415];
276276

277277
/**
278278
* Add a transfer on the TD linked list associated to an ED

0 commit comments

Comments
 (0)