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

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

Issue 1154323007: Split network_interfaces.h off of net_utils.h. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ip_util
Patch Set: address matt's comments Created 5 years, 6 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
« no previous file with comments | « net/base/net_util.h ('k') | net/base/net_util_linux.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/net_util.h" 5 #include "net/base/net_util.h"
6 6
7 #include <errno.h> 7 #include <errno.h>
8 #include <string.h> 8 #include <string.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 777 matching lines...) Expand 10 before | Expand all | Expand 10 after
788 ".ytimg.com", 788 ".ytimg.com",
789 }; 789 };
790 const std::string& host = url.host(); 790 const std::string& host = url.host();
791 for (const char* suffix : kGoogleHostSuffixes) { 791 for (const char* suffix : kGoogleHostSuffixes) {
792 if (EndsWith(host, suffix, false)) 792 if (EndsWith(host, suffix, false))
793 return true; 793 return true;
794 } 794 }
795 return false; 795 return false;
796 } 796 }
797 797
798 NetworkInterface::NetworkInterface()
799 : type(NetworkChangeNotifier::CONNECTION_UNKNOWN), prefix_length(0) {
800 }
801
802 NetworkInterface::NetworkInterface(const std::string& name,
803 const std::string& friendly_name,
804 uint32 interface_index,
805 NetworkChangeNotifier::ConnectionType type,
806 const IPAddressNumber& address,
807 uint32 prefix_length,
808 int ip_address_attributes)
809 : name(name),
810 friendly_name(friendly_name),
811 interface_index(interface_index),
812 type(type),
813 address(address),
814 prefix_length(prefix_length),
815 ip_address_attributes(ip_address_attributes) {
816 }
817
818 NetworkInterface::~NetworkInterface() {
819 }
820
821 ScopedWifiOptions::~ScopedWifiOptions() {
822 }
823
824 } // namespace net 798 } // namespace net
OLDNEW
« no previous file with comments | « net/base/net_util.h ('k') | net/base/net_util_linux.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698