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

Side by Side Diff: net/dns/mapped_host_resolver.cc

Issue 2811183003: Change Cronet's "disable_ipv6" to "disable_ipv6_on_wifi" (Closed)
Patch Set: Created 3 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 unified diff | Download patch
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/dns/mapped_host_resolver.h" 5 #include "net/dns/mapped_host_resolver.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/values.h" 10 #include "base/values.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 } 57 }
58 58
59 void MappedHostResolver::SetDefaultAddressFamily(AddressFamily address_family) { 59 void MappedHostResolver::SetDefaultAddressFamily(AddressFamily address_family) {
60 impl_->SetDefaultAddressFamily(address_family); 60 impl_->SetDefaultAddressFamily(address_family);
61 } 61 }
62 62
63 AddressFamily MappedHostResolver::GetDefaultAddressFamily() const { 63 AddressFamily MappedHostResolver::GetDefaultAddressFamily() const {
64 return impl_->GetDefaultAddressFamily(); 64 return impl_->GetDefaultAddressFamily();
65 } 65 }
66 66
67 void MappedHostResolver::SetNoIPv6OnWifi() {
68 impl_->SetNoIPv6OnWifi();
69 }
70
71 bool MappedHostResolver::GetNoIPv6OnWifi() {
72 return impl_->GetNoIPv6OnWifi();
73 }
74
67 int MappedHostResolver::ApplyRules(RequestInfo* info) const { 75 int MappedHostResolver::ApplyRules(RequestInfo* info) const {
68 HostPortPair host_port(info->host_port_pair()); 76 HostPortPair host_port(info->host_port_pair());
69 if (rules_.RewriteHost(&host_port)) { 77 if (rules_.RewriteHost(&host_port)) {
70 if (host_port.host() == "~NOTFOUND") 78 if (host_port.host() == "~NOTFOUND")
71 return ERR_NAME_NOT_RESOLVED; 79 return ERR_NAME_NOT_RESOLVED;
72 info->set_host_port_pair(host_port); 80 info->set_host_port_pair(host_port);
73 } 81 }
74 return OK; 82 return OK;
75 } 83 }
76 84
77 } // namespace net 85 } // namespace net
OLDNEW
« net/dns/host_resolver_impl.cc ('K') | « net/dns/mapped_host_resolver.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698