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

Unified Diff: net/dns/dns_config_service.cc

Issue 21368005: Detect domain-specific resolvers on OS X and disable DnsClient in such cases. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: responded to review Created 7 years, 4 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 | « net/dns/dns_config_service.h ('k') | net/dns/dns_config_service_posix.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/dns/dns_config_service.cc
diff --git a/net/dns/dns_config_service.cc b/net/dns/dns_config_service.cc
index ea8a3421cd2263c4521b5dd0ee5ba160d331a4ee..d7af988cf86b8a3c8aef66857d4a5932e34f8fe2 100644
--- a/net/dns/dns_config_service.cc
+++ b/net/dns/dns_config_service.cc
@@ -14,7 +14,8 @@ namespace net {
// Default values are taken from glibc resolv.h except timeout which is set to
// |kDnsTimeoutSeconds|.
DnsConfig::DnsConfig()
- : append_to_multi_label_name(true),
+ : unhandled_options(false),
+ append_to_multi_label_name(true),
randomize_ports(false),
ndots(1),
timeout(base::TimeDelta::FromSeconds(kDnsTimeoutSeconds)),
@@ -31,6 +32,7 @@ bool DnsConfig::Equals(const DnsConfig& d) const {
bool DnsConfig::EqualsIgnoreHosts(const DnsConfig& d) const {
return (nameservers == d.nameservers) &&
(search == d.search) &&
+ (unhandled_options == d.unhandled_options) &&
(append_to_multi_label_name == d.append_to_multi_label_name) &&
(ndots == d.ndots) &&
(timeout == d.timeout) &&
@@ -42,6 +44,7 @@ bool DnsConfig::EqualsIgnoreHosts(const DnsConfig& d) const {
void DnsConfig::CopyIgnoreHosts(const DnsConfig& d) {
nameservers = d.nameservers;
search = d.search;
+ unhandled_options = d.unhandled_options;
append_to_multi_label_name = d.append_to_multi_label_name;
ndots = d.ndots;
timeout = d.timeout;
@@ -63,6 +66,7 @@ base::Value* DnsConfig::ToValue() const {
list->Append(new base::StringValue(search[i]));
dict->Set("search", list);
+ dict->SetBoolean("unhandled_options", unhandled_options);
dict->SetBoolean("append_to_multi_label_name", append_to_multi_label_name);
dict->SetInteger("ndots", ndots);
dict->SetDouble("timeout", timeout.InSecondsF());
« no previous file with comments | « net/dns/dns_config_service.h ('k') | net/dns/dns_config_service_posix.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698