From ca811aaa7d0beecd2e0bd5c58b3794febb2f07c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Hejl?= Date: Thu, 4 Jan 2024 00:11:03 +0100 Subject: [PATCH] Move the function ptree_get_value() inside _WIN32 ifdef. --- src/slic3r/Utils/WifiScanner.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/slic3r/Utils/WifiScanner.cpp b/src/slic3r/Utils/WifiScanner.cpp index 260583516d..aa4c8f4e9f 100644 --- a/src/slic3r/Utils/WifiScanner.cpp +++ b/src/slic3r/Utils/WifiScanner.cpp @@ -24,6 +24,8 @@ #endif //__linux__ namespace { + +#ifdef _WIN32 bool ptree_get_value(const boost::property_tree::ptree& pt, const std::string& target, std::string& result) { // Check if the current node has the target element @@ -41,7 +43,7 @@ bool ptree_get_value(const boost::property_tree::ptree& pt, const std::string& t return false; // Element not found in this subtree } -#ifdef _WIN32 + // Fill SSID map. Implementation from Raspberry Pi imager and Win32 Api examples. // https://github.com/raspberrypi/rpi-imager/blob/qml/src/windows/winwlancredentials.cpp // https://learn.microsoft.com/en-us/windows/win32/api/wlanapi/nf-wlanapi-wlangetavailablenetworklist