Skip to content

Commit 60881f4

Browse files
committed
Add error log with mbedtls_ssl_setup error code.
SSL handshake seems to fail sometimes (meshtastic/firmware#6960) but we need more detail on the mbedtls_ssl_setup error code to identify the problem. 'Web Client Rebuild' group is also seeing some '[HTTPS:E] SSL handshake failed.', we need more info to determine if it's related to the bug report above or something unrelated.
1 parent b0f3960 commit 60881f4

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/HTTPSConnection.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ bool HTTPSConnection::setup(mbedtls_ssl_config *sslConfig) {
2525
if (res == 0) {
2626
return true;
2727
} else {
28+
char buf[100];
29+
mbedtls_strerror(res, buf, sizeof(buf));
30+
HTTPS_LOGE("mbedtls_ssl_setup res=%X (%s)", res, buf);
2831
mbedtls_ssl_free(&_ssl);
2932
return false;
3033
}

0 commit comments

Comments
 (0)