mirror of
https://github.com/kidfromjupiter/nearby.git
synced 2026-09-16 07:36:10 -04:00
Wi-Fi Direct Service Implementation(8.3)
PiperOrigin-RevId: 843969255
This commit is contained in:
@@ -160,7 +160,10 @@ WifiDirectBwuHandler::CreateUpgradedEndpointChannel(
|
||||
LOG(INFO) << "Received WifiDirect credential SSID: " << ssid
|
||||
<< ", Password: " << masker::Mask(password)
|
||||
<< ", Port: " << port << ", Gateway: " << gateway
|
||||
<< ", Frequency: " << freq;
|
||||
<< ", Frequency: " << freq
|
||||
<< ". SSID/PASSWORD auth type is not supported, return";
|
||||
return {Error(
|
||||
OperationResultCode::CONNECTIVITY_WIFI_DIRECT_INVALID_CREDENTIAL)};
|
||||
}
|
||||
|
||||
if (!wifi_direct_medium_.ConnectWifiDirect(wifi_direct_credentials)) {
|
||||
|
||||
@@ -316,7 +316,7 @@ bool WifiDirectMedium::StartWifiDirect(
|
||||
|
||||
try {
|
||||
advertiser_.Start();
|
||||
LOG(INFO) << "Start WifiDirect GO succeeded. Status: "
|
||||
LOG(INFO) << "Start WifiDirect GO Status: "
|
||||
<< (int)advertiser_.AdvertisementStatus();
|
||||
if ((advertiser_.AdvertisementStatus() ==
|
||||
WiFiDirectServiceAdvertisementStatus::Created) ||
|
||||
@@ -555,6 +555,10 @@ bool WifiDirectMedium::ConnectWifiDirect(
|
||||
}
|
||||
|
||||
credentials_gc_ = credentials;
|
||||
if (credentials_gc_.GetServiceName().empty()) {
|
||||
LOG(ERROR) << "GC: Service name is empty, return false";
|
||||
return false;
|
||||
}
|
||||
winrt::hstring device_selector = WiFiDirectService::GetSelector(
|
||||
winrt::to_hstring(credentials_gc_.GetServiceName()));
|
||||
const winrt::param::iterable<winrt::hstring> requested_properties =
|
||||
|
||||
Reference in New Issue
Block a user