mirror of
https://github.com/espressif/ESP8266_RTOS_SDK.git
synced 2025-12-11 23:57:08 +08:00
bugfix/tls_handshake: Fixed an error check during TLS handshake.
(cherry picked from commit fb8b45cf0665d7cca1415430a22c1d74d17d9827)
This commit is contained in:
@@ -107,7 +107,7 @@ IoT_Error_t iot_tls_connect(Network *pNetwork, TLSConnectParams *params) {
|
||||
ret = SSL_CONNECTION_ERROR;
|
||||
} else {
|
||||
int tls_ret = esp_tls_conn_new_sync(pNetwork->tlsConnectParams.pDestinationURL, strlen(pNetwork->tlsConnectParams.pDestinationURL), pNetwork->tlsConnectParams.DestinationPort, &cfg, tls);
|
||||
if (tls_ret) {
|
||||
if (tls_ret == -1) {
|
||||
ret = SSL_CONNECTION_ERROR;
|
||||
esp_tls_conn_delete(tls);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user