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

Unified Diff: net/dns/dns_client.h

Issue 10442098: [net/dns] Resolve AF_UNSPEC on dual-stacked systems. Sort addresses according to RFC3484. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Handle ifa_netmnask == NULL and other errors after getifaddrs. Created 8 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
Index: net/dns/dns_client.h
diff --git a/net/dns/dns_client.h b/net/dns/dns_client.h
index 13aa0bf8ed1183320180b4482110a15540df6e93..650c7d0d4166aee2f0591a4fb0edd6663474bdd0 100644
--- a/net/dns/dns_client.h
+++ b/net/dns/dns_client.h
@@ -10,12 +10,14 @@
namespace net {
+class AddressSorter;
struct DnsConfig;
class DnsTransactionFactory;
class NetLog;
-// Convenience wrapper allows easy injection of DnsTransaction into
-// HostResolverImpl.
+// Convenience wrapper which allows easy injection of DnsTransaction into
+// HostResolverImpl. Pointers returned by the Get* methods are only guaranteed
+// to remain valid until next time SetConfig is called.
class NET_EXPORT DnsClient {
public:
virtual ~DnsClient() {}
@@ -29,6 +31,9 @@ class NET_EXPORT DnsClient {
// Returns NULL if the current config is not valid.
virtual DnsTransactionFactory* GetTransactionFactory() = 0;
+ // Returns NULL if the current config is not valid.
+ virtual AddressSorter* GetAddressSorter() = 0;
+
// Creates default client.
static scoped_ptr<DnsClient> CreateClient(NetLog* net_log);
};

Powered by Google App Engine
This is Rietveld 408576698