mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-05 05:34:32 +02:00
Merge branch 'bugfix/ota_failed_with_openssl_3.0.2' into 'master'
fix(esp_http_client): Fix ota failure with openssl server Closes IDFGH-13879 and IDF-7885 See merge request espressif/esp-idf!34189
This commit is contained in:
@@ -1247,7 +1247,6 @@ int esp_http_client_read(esp_http_client_handle_t client, char *buffer, int len)
|
|||||||
ESP_LOGD(TAG, "need_read=%d, byte_to_read=%d, rlen=%d, ridx=%d", need_read, byte_to_read, rlen, ridx);
|
ESP_LOGD(TAG, "need_read=%d, byte_to_read=%d, rlen=%d, ridx=%d", need_read, byte_to_read, rlen, ridx);
|
||||||
|
|
||||||
if (rlen <= 0) {
|
if (rlen <= 0) {
|
||||||
if (errno != 0) {
|
|
||||||
esp_log_level_t sev = ESP_LOG_WARN;
|
esp_log_level_t sev = ESP_LOG_WARN;
|
||||||
/* Check for cleanly closed connection */
|
/* Check for cleanly closed connection */
|
||||||
if (rlen == ERR_TCP_TRANSPORT_CONNECTION_CLOSED_BY_FIN && client->response->is_chunked) {
|
if (rlen == ERR_TCP_TRANSPORT_CONNECTION_CLOSED_BY_FIN && client->response->is_chunked) {
|
||||||
@@ -1256,6 +1255,7 @@ int esp_http_client_read(esp_http_client_handle_t client, char *buffer, int len)
|
|||||||
/* ...and lowering the message severity, as closed connection from server side is expected in chunked transport */
|
/* ...and lowering the message severity, as closed connection from server side is expected in chunked transport */
|
||||||
sev = ESP_LOG_DEBUG;
|
sev = ESP_LOG_DEBUG;
|
||||||
}
|
}
|
||||||
|
if (errno != 0) {
|
||||||
ESP_LOG_LEVEL(sev, TAG, "esp_transport_read returned:%d and errno:%d ", rlen, errno);
|
ESP_LOG_LEVEL(sev, TAG, "esp_transport_read returned:%d and errno:%d ", rlen, errno);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user