Skip to content

Commit 1297790

Browse files
authored
tx_ring_buf not checked for successful allocation
1 parent b111c84 commit 1297790

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

components/esp_driver_usb_serial_jtag/src/usb_serial_jtag.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ esp_err_t usb_serial_jtag_driver_install(usb_serial_jtag_driver_config_t *usb_se
183183
}
184184

185185
p_usb_serial_jtag_obj->tx_ring_buf = xRingbufferCreate(usb_serial_jtag_config->tx_buffer_size, RINGBUF_TYPE_BYTEBUF);
186-
if (p_usb_serial_jtag_obj->rx_ring_buf == NULL) {
186+
if (p_usb_serial_jtag_obj->tx_ring_buf == NULL) {
187187
ESP_LOGE(USB_SERIAL_JTAG_TAG, "ringbuffer create error");
188188
err = ESP_ERR_NO_MEM;
189189
goto _exit;

0 commit comments

Comments
 (0)