mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-06 06:04:33 +02:00
Merge branch 'examples/tcp_server_inner_loop_fix' into 'master'
socket examples: Fix for send() failure handling. Closes IDFGH-7962 See merge request espressif/esp-idf!20043
This commit is contained in:
@@ -53,6 +53,8 @@ static void do_retransmit(const int sock)
|
||||
int written = send(sock, rx_buffer + (len - to_write), to_write, 0);
|
||||
if (written < 0) {
|
||||
ESP_LOGE(TAG, "Error occurred during sending: errno %d", errno);
|
||||
// Failed to retransmit, giving up
|
||||
return;
|
||||
}
|
||||
to_write -= written;
|
||||
}
|
||||
|
Reference in New Issue
Block a user