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

Unified Diff: net/base/net_util.h

Issue 231973003: Adding network interface type param to net::NetworkInterface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/local_discovery/privet_traffic_detector.cc ('k') | net/base/net_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/net_util.h
diff --git a/net/base/net_util.h b/net/base/net_util.h
index fdf103b2ebcc73962322569a928ebc265e89ce82..d822f6926d8397e3d07311de6eb3c93f2ed77f75 100644
--- a/net/base/net_util.h
+++ b/net/base/net_util.h
@@ -416,6 +416,15 @@ NET_EXPORT_PRIVATE int GetPortFromSockaddr(const struct sockaddr* address,
// machine.
NET_EXPORT_PRIVATE bool IsLocalhost(const std::string& host);
+// Category of network interface types.
+enum NetworkInterfaceType {
+ NETWORK_INTERFACE_UNKNOWN,
+ NETWORK_INTERFACE_ETHERNET,
+ NETWORK_INTERFACE_WIFI,
+ NETWORK_INTERFACE_CELLULAR,
+ NETWORK_INTERFACE_VPN
+};
+
// struct that is used by GetNetworkList() to represent a network
// interface.
struct NET_EXPORT NetworkInterface {
@@ -423,6 +432,7 @@ struct NET_EXPORT NetworkInterface {
NetworkInterface(const std::string& name,
const std::string& friendly_name,
uint32 interface_index,
+ NetworkInterfaceType type,
const IPAddressNumber& address,
size_t network_prefix);
~NetworkInterface();
@@ -430,6 +440,7 @@ struct NET_EXPORT NetworkInterface {
std::string name;
std::string friendly_name; // Same as |name| on non-Windows.
uint32 interface_index; // Always 0 on Android.
+ NetworkInterfaceType type;
IPAddressNumber address;
size_t network_prefix;
};
« no previous file with comments | « chrome/browser/local_discovery/privet_traffic_detector.cc ('k') | net/base/net_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698