mirror of
https://gitee.com/openharmony/communication_wifi.git
synced 2024-11-23 07:00:07 +00:00
update
Signed-off-by: yangpengfei <yangpengfei34@huawei.com>
This commit is contained in:
parent
13b919cb9b
commit
1e587054cb
@ -84,16 +84,17 @@ void NetworkSelectionManager::GetAllDeviceConfigs(std::vector<NetworkSelection::
|
||||
wifiDeviceConfigs.insert({networkCandidate.wifiDeviceConfig.networkId, networkCandidates.size() - 1});
|
||||
continue;
|
||||
}
|
||||
|
||||
// add suggesion network
|
||||
WifiSettings::GetInstance().GetCandidateConfigWithoutUid(scanInfo.ssid, deviceKeyMgmt,
|
||||
networkCandidate.wifiDeviceConfig);
|
||||
if (networkCandidates.back().wifiDeviceConfig.networkId != INVALID_NETWORK_ID &&
|
||||
networkCandidates.back().wifiDeviceConfig.uid != WIFI_INVALID_UID &&
|
||||
networkCandidates.back().wifiDeviceConfig.isShared == false) {
|
||||
wifiCandidateConfigs.insert({networkCandidate.wifiDeviceConfig.networkId, networkCandidates.size() - 1});
|
||||
}
|
||||
}
|
||||
|
||||
// add suggesion network
|
||||
WifiSettings::GetInstance().GetCandidateConfigWithoutUid(scanInfo.ssid, deviceKeyMgmt,
|
||||
networkCandidate.wifiDeviceConfig);
|
||||
if (networkCandidates.back().wifiDeviceConfig.networkId != INVALID_NETWORK_ID &&
|
||||
networkCandidates.back().wifiDeviceConfig.uid != WIFI_INVALID_UID &&
|
||||
networkCandidates.back().wifiDeviceConfig.isShared == IS_SUGGESTION_NETWORK) {
|
||||
wifiCandidateConfigs.insert({networkCandidate.wifiDeviceConfig.networkId, networkCandidates.size() - 1});
|
||||
}
|
||||
std::stringstream wifiDevicesInfo;
|
||||
for (auto &pair: wifiDeviceConfigs) {
|
||||
if (wifiDevicesInfo.rdbuf() ->in_avail() != 0) {
|
||||
|
@ -37,10 +37,9 @@ public:
|
||||
class BlockConnectService : public MockBlockConnectService {
|
||||
public:
|
||||
BlockConnectService() = default;
|
||||
~BlockConnectService() = default;
|
||||
~BlockConnectService() override;
|
||||
static BlockConnectService &GetInstance(void);
|
||||
|
||||
|
||||
|
||||
MOCK_METHOD1(ShouldAutoConnect, bool(const WifiDeviceConfig &config));
|
||||
MOCK_METHOD0(UpdateAllNetworkSelectStatus, bool());
|
||||
MOCK_METHOD3(UpdateNetworkSelectStatus, bool(int targetNetworkId, DisabledReason disableReason, int wpaReason));
|
||||
|
Loading…
Reference in New Issue
Block a user