stm32: cdcacm: fix array out of bounds write
Remove debug leftovers that were causing memory corruption. Writes of 64 or more bytes from the USB host side caused memory corruption before this commit. I've tested it in a STM32L4 board and it is working as expected.
This commit is contained in:
@@ -212,7 +212,6 @@ static void cdcacm_data_rx_cb(usbd_device *usbd_dev, uint8_t ep)
|
||||
|
||||
if (len) {
|
||||
usbd_ep_write_packet(usbd_dev, 0x82, buf, len);
|
||||
buf[len] = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user