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

Unified Diff: chrome/browser/extensions/api/dns/dns_api.h

Issue 10071035: RefCounted types should not have public destructors, chrome/browser/extensions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Compile fix Created 8 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
Index: chrome/browser/extensions/api/dns/dns_api.h
diff --git a/chrome/browser/extensions/api/dns/dns_api.h b/chrome/browser/extensions/api/dns/dns_api.h
index 113d9955eee0698a35b203ea401f6eaf9f507fc7..35be14a063282f592c617915cf4b2672972773c1 100644
--- a/chrome/browser/extensions/api/dns/dns_api.h
+++ b/chrome/browser/extensions/api/dns/dns_api.h
@@ -21,20 +21,26 @@ namespace extensions {
class DnsResolveFunction : public AsyncExtensionFunction {
public:
- DnsResolveFunction();
- virtual ~DnsResolveFunction();
+ DECLARE_EXTENSION_FUNCTION_NAME("experimental.dns.resolve")
- virtual bool RunImpl() OVERRIDE;
+ DnsResolveFunction();
// See below. Caller retains ownership.
static void set_host_resolver_for_testing(
net::HostResolver* host_resolver_for_testing);
protected:
+ virtual ~DnsResolveFunction();
+
+ // ExtensionFunction:
+ virtual bool RunImpl() OVERRIDE;
+
void WorkOnIOThread();
void RespondOnUIThread();
private:
+ void OnLookupFinished(int result);
+
std::string hostname_;
bool response_; // The value sent in SendResponse().
@@ -44,18 +50,9 @@ class DnsResolveFunction : public AsyncExtensionFunction {
// plain pointer to it here as we move from thread to thread.
IOThread* io_thread_;
- // If null, then we'll use io_thread_ to obtain the real HostResolver. We use
- // a plain pointer for to be consistent with the ownership model of the real
- // one.
- static net::HostResolver* host_resolver_for_testing;
-
scoped_ptr<net::CapturingBoundNetLog> capturing_bound_net_log_;
scoped_ptr<net::HostResolver::RequestHandle> request_handle_;
scoped_ptr<net::AddressList> addresses_;
-
- void OnLookupFinished(int result);
-
- DECLARE_EXTENSION_FUNCTION_NAME("experimental.dns.resolve")
};
} // namespace extensions

Powered by Google App Engine
This is Rietveld 408576698