From 229d9b7366deee0d8a90fb69c19119f7287c9d1d Mon Sep 17 00:00:00 2001 From: copercini Date: Mon, 31 Dec 2018 07:44:57 -0200 Subject: [PATCH] [WiFiClientSecure] Shows only free internal heap on logs (#2252) * Shows only free internal heap on logs Since Mbedtls is running only on internal heap, show internal + PSRAM available memory on logs can confuse the users * Clarify logs --- libraries/WiFiClientSecure/src/ssl_client.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/WiFiClientSecure/src/ssl_client.cpp b/libraries/WiFiClientSecure/src/ssl_client.cpp index 25bca677..c879b8b1 100644 --- a/libraries/WiFiClientSecure/src/ssl_client.cpp +++ b/libraries/WiFiClientSecure/src/ssl_client.cpp @@ -50,7 +50,7 @@ int start_ssl_client(sslclient_context *ssl_client, const char *host, uint32_t p char buf[512]; int ret, flags, timeout; int enable = 1; - log_v("Free heap before TLS %u", xPortGetFreeHeapSize()); + log_v("Free internal heap before TLS %u", ESP.getFreeHeap()); log_v("Starting socket"); ssl_client->socket = -1; @@ -232,7 +232,7 @@ int start_ssl_client(sslclient_context *ssl_client, const char *host, uint32_t p mbedtls_pk_free(&ssl_client->client_key); } - log_v("Free heap after TLS %u", xPortGetFreeHeapSize()); + log_v("Free internal heap after TLS %u", ESP.getFreeHeap()); return ssl_client->socket; }