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

Unified Diff: net/proxy/proxy_script_fetcher_impl.h

Issue 2845643003: Allow ProxyService to share URLRequestContext with everything else. (Closed)
Patch Set: Fix fetcher shutdown with no active request, add test, add comment 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/proxy/proxy_script_fetcher.h ('k') | net/proxy/proxy_script_fetcher_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/proxy/proxy_script_fetcher_impl.h
diff --git a/net/proxy/proxy_script_fetcher_impl.h b/net/proxy/proxy_script_fetcher_impl.h
index 7a24bf8a2dbc72a7acfa30f9ba9265a21f3ad585..bc1e1928fb09130c370857dbe777079c2b06f183 100644
--- a/net/proxy/proxy_script_fetcher_impl.h
+++ b/net/proxy/proxy_script_fetcher_impl.h
@@ -53,6 +53,7 @@ class NET_EXPORT ProxyScriptFetcherImpl : public ProxyScriptFetcher,
const CompletionCallback& callback) override;
void Cancel() override;
URLRequestContext* GetRequestContext() const override;
+ void OnShutdown() override;
// URLRequest::Delegate methods:
void OnAuthRequired(URLRequest* request,
@@ -83,8 +84,9 @@ class NET_EXPORT ProxyScriptFetcherImpl : public ProxyScriptFetcher,
// Callback for time-out task of request with id |id|.
void OnTimeout(int id);
- // The context used for making network requests.
- URLRequestContext* const url_request_context_;
+ // The context used for making network requests. Set to nullptr by
+ // OnShutdown.
+ URLRequestContext* url_request_context_;
// Buffer that URLRequest writes into.
scoped_refptr<IOBuffer> buf_;
« no previous file with comments | « net/proxy/proxy_script_fetcher.h ('k') | net/proxy/proxy_script_fetcher_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698