Loading wifi/1.3/default/wifi_chip.cpp +4 −5 Original line number Diff line number Diff line Loading @@ -86,16 +86,15 @@ std::string getWlanIfaceName(unsigned idx) { } std::array<char, PROPERTY_VALUE_MAX> buffer; std::string propName = "wifi.interface." + std::to_string(idx); auto res = property_get(propName.c_str(), buffer.data(), nullptr); if (res > 0) return buffer.data(); if (idx == 0 || idx == 1) { const char* altPropName = (idx == 0) ? "wifi.interface" : "wifi.concurrent.interface"; res = property_get(altPropName, buffer.data(), nullptr); auto res = property_get(altPropName, buffer.data(), nullptr); if (res > 0) return buffer.data(); } std::string propName = "wifi.interface." + std::to_string(idx); auto res = property_get(propName.c_str(), buffer.data(), nullptr); if (res > 0) return buffer.data(); return "wlan" + std::to_string(idx); } Loading Loading
wifi/1.3/default/wifi_chip.cpp +4 −5 Original line number Diff line number Diff line Loading @@ -86,16 +86,15 @@ std::string getWlanIfaceName(unsigned idx) { } std::array<char, PROPERTY_VALUE_MAX> buffer; std::string propName = "wifi.interface." + std::to_string(idx); auto res = property_get(propName.c_str(), buffer.data(), nullptr); if (res > 0) return buffer.data(); if (idx == 0 || idx == 1) { const char* altPropName = (idx == 0) ? "wifi.interface" : "wifi.concurrent.interface"; res = property_get(altPropName, buffer.data(), nullptr); auto res = property_get(altPropName, buffer.data(), nullptr); if (res > 0) return buffer.data(); } std::string propName = "wifi.interface." + std::to_string(idx); auto res = property_get(propName.c_str(), buffer.data(), nullptr); if (res > 0) return buffer.data(); return "wlan" + std::to_string(idx); } Loading