BugID:17132117: [WhiteScan] Fix integer index overflow error during read uart ringbuffer array
@@ -53,7 +53,7 @@ int32_t hal_uart_finalize(uart_dev_t *uart)
int32_t hal_uart_send(uart_dev_t *uart, const void *data, uint32_t size, uint32_t timeout)
{
- if (uart->port > MICO_UART_MAX)
+ if (uart->port >= MICO_UART_MAX)
return -1;
platform_uart_transmit_bytes(&platform_uart_drivers[uart->port], data, size);
