From 26b78089cc3549c1dc26bad28ace2d4568018ea9 Mon Sep 17 00:00:00 2001 From: Krzysztof Strehlau Date: Tue, 2 Jul 2024 00:36:46 +0200 Subject: [PATCH] Update ksWifiConnector.cpp --- src/ksf/comp/ksWifiConnector.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/ksf/comp/ksWifiConnector.cpp b/src/ksf/comp/ksWifiConnector.cpp index e5788cb..20eee6c 100644 --- a/src/ksf/comp/ksWifiConnector.cpp +++ b/src/ksf/comp/ksWifiConnector.cpp @@ -29,11 +29,12 @@ namespace ksf::comps inline void overrideDnsWithGoogleDns() { /* Define override DNS addresses. */ - static const IPAddress primaryDns{LWIP_MAKEU32(8, 8, 8, 8)}; - static const IPAddress secondaryDns{LWIP_MAKEU32(8, 8, 4, 4)}; + static const ip_addr primaryDns{LWIP_MAKEU32(8, 8, 8, 8)}; + static const ip_addr secondaryDns{LWIP_MAKEU32(8, 8, 4, 4)}; /* Set DNS servers. */ - WiFi.setDNS(primaryDns, secondaryDns); + dns_setserver(0, &primaryDns); + dns_setserver(1, &secondaryDns); } ksWifiConnector::ksWifiConnector(const char* hostname, bool savePower)