diff --git a/cpp/core/internal/offline_frames_validator.cc b/cpp/core/internal/offline_frames_validator.cc index 807997e2..209d206b 100644 --- a/cpp/core/internal/offline_frames_validator.cc +++ b/cpp/core/internal/offline_frames_validator.cc @@ -35,6 +35,7 @@ using WifiAwareCredentials = UpgradePathInfo::WifiAwareCredentials; using WifiDirectCredentials = UpgradePathInfo::WifiDirectCredentials; using BluetoothCredentials = UpgradePathInfo::BluetoothCredentials; using WebRtcCredentials = UpgradePathInfo::WebRtcCredentials; +using Medium = location::nearby::connections::Medium; constexpr absl::string_view kIpv4PatternString{ "^([01]?\\d\\d?|2[0-4]\\d|25[0-5])\\." @@ -239,7 +240,7 @@ Exception EnsureValidBandwidthUpgradePathAvailableFrame( const UpgradePathInfo& upgrade_path_info) { if (!upgrade_path_info.has_medium()) return {Exception::kInvalidProtocolBuffer}; - switch (upgrade_path_info.medium()) { + switch (static_cast(upgrade_path_info.medium())) { case Medium::WIFI_HOTSPOT: if (upgrade_path_info.has_wifi_hotspot_credentials()) { return EnsureValidBandwidthUpgradeWifiHotspotPathAvailableFrame( diff --git a/cpp/core/internal/wifi_lan_bwu_handler.cc b/cpp/core/internal/wifi_lan_bwu_handler.cc index d0585d87..93d0dd40 100644 --- a/cpp/core/internal/wifi_lan_bwu_handler.cc +++ b/cpp/core/internal/wifi_lan_bwu_handler.cc @@ -110,7 +110,7 @@ WifiLanBwuHandler::CreateUpgradedEndpointChannel( } const std::string& ip_address = wifi_lan_socket.ip_address(); - int32 port = wifi_lan_socket.wifi_port(); + std::int32_t port = wifi_lan_socket.wifi_port(); WifiLanService wifi_lan_service = wifi_lan_medium_.GetRemoteWifiLanService(ip_address, port);