mirror of
https://github.com/espressif/esp-idf.git
synced 2025-12-08 01:17:07 +00:00
fix(uart): add check for malloc in uart examples
Closes https://github.com/espressif/esp-idf/issues/13405
This commit is contained in:
@@ -94,6 +94,7 @@ static void echo_task(void *arg)
|
||||
|
||||
// Allocate buffers for UART
|
||||
uint8_t* data = (uint8_t*) malloc(BUF_SIZE);
|
||||
assert(data);
|
||||
|
||||
ESP_LOGI(TAG, "UART start receive loop.\r");
|
||||
echo_send(uart_num, "Start RS485 UART test.\r\n", 24);
|
||||
|
||||
Reference in New Issue
Block a user