Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(410)

Side by Side Diff: net/base/network_interfaces_linux.cc

Issue 1633733005: Native SSID extraction moved to platform code on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: getCurrentWifiConnectionSsid renamed to getWifiSSID Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "net/base/network_interfaces_linux.h" 5 #include "net/base/network_interfaces_linux.h"
6 6
7 #if !defined(OS_ANDROID) 7 #if !defined(OS_ANDROID)
8 #include <linux/ethtool.h> 8 #include <linux/ethtool.h>
9 #endif // !defined(OS_ANDROID) 9 #endif // !defined(OS_ANDROID)
10 #include <linux/if.h> 10 #include <linux/if.h>
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 return false; 208 return false;
209 209
210 internal::AddressTrackerLinux tracker; 210 internal::AddressTrackerLinux tracker;
211 tracker.Init(); 211 tracker.Init();
212 212
213 return internal::GetNetworkListImpl( 213 return internal::GetNetworkListImpl(
214 networks, policy, tracker.GetOnlineLinks(), tracker.GetAddressMap(), 214 networks, policy, tracker.GetOnlineLinks(), tracker.GetAddressMap(),
215 &internal::AddressTrackerLinux::GetInterfaceName); 215 &internal::AddressTrackerLinux::GetInterfaceName);
216 } 216 }
217 217
218 #if !defined(OS_ANDROID)
218 std::string GetWifiSSID() { 219 std::string GetWifiSSID() {
219 NetworkInterfaceList networks; 220 NetworkInterfaceList networks;
220 if (GetNetworkList(&networks, INCLUDE_HOST_SCOPE_VIRTUAL_INTERFACES)) { 221 if (GetNetworkList(&networks, INCLUDE_HOST_SCOPE_VIRTUAL_INTERFACES)) {
221 return internal::GetWifiSSIDFromInterfaceListInternal( 222 return internal::GetWifiSSIDFromInterfaceListInternal(
222 networks, internal::GetInterfaceSSID); 223 networks, internal::GetInterfaceSSID);
223 } 224 }
224 return ""; 225 return "";
225 } 226 }
227 #endif // !defined(OS_ANDROID)
226 228
227 } // namespace net 229 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698