Merge branch 'bugfix/fix_disable_https_client_build_error' into 'master'

esp_http_client: Fix disable CONFIG_ESP_HTTP_CLIENT_ENABLE_HTTPS will build error

Closes IDFGH-5640

See merge request espressif/esp-idf!14833
This commit is contained in:
Mahavir Jain
2021-08-23 06:30:46 +00:00
2 changed files with 2 additions and 1 deletions

View File

@@ -1056,7 +1056,7 @@ esp_err_t esp_http_client_perform(esp_http_client_handle_t client)
if (client->is_async && errno == EAGAIN) {
return ESP_ERR_HTTP_EAGAIN;
}
if (esp_tls_get_and_clear_last_error(esp_transport_get_error_handle(client->transport), NULL, NULL) == ESP_ERR_ESP_TLS_TCP_CLOSED_FIN) {
if (esp_transport_get_errno(client->transport) == ENOTCONN) {
ESP_LOGW(TAG, "Close connection due to FIN received");
esp_http_client_close(client);
http_dispatch_event(client, HTTP_EVENT_ERROR, esp_transport_get_error_handle(client->transport), 0);

View File

@@ -0,0 +1 @@
CONFIG_ESP_HTTP_CLIENT_ENABLE_HTTPS=n