From 8539f015c30677578d0afa44e399d57af1f91c40 Mon Sep 17 00:00:00 2001 From: Hieromon Ikasamo Date: Fri, 18 Oct 2019 00:29:44 +0900 Subject: [PATCH] Fixed garbage returning when no SSID found. --- src/AutoConnectPage.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/AutoConnectPage.cpp b/src/AutoConnectPage.cpp index 047b6cc..974df4d 100644 --- a/src/AutoConnectPage.cpp +++ b/src/AutoConnectPage.cpp @@ -1177,6 +1177,7 @@ String AutoConnect::_token_LIST_SSID(PageArgument& args) { uint8_t validCount = 0; uint8_t dispCount = 0; char* slBuf = ssidList; + *slBuf = '\0'; for (uint8_t i = 0; i < _scanCount; i++) { String ssid = WiFi.SSID(i); if (ssid.length() > 0) {