diff options
author | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-20 20:55:17 +0000 |
---|---|---|
committer | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-07-20 20:55:17 +0000 |
commit | 2447640cc25951a7522c0b655f3482ca9cc1c27b (patch) | |
tree | d54947c9fb370362b387ade837869eceb2d9ad2f /net/proxy/init_proxy_resolver.h | |
parent | 28900505e2304ff77769f8fce09b575eab33fc85 (diff) | |
download | chromium_src-2447640cc25951a7522c0b655f3482ca9cc1c27b.zip chromium_src-2447640cc25951a7522c0b655f3482ca9cc1c27b.tar.gz chromium_src-2447640cc25951a7522c0b655f3482ca9cc1c27b.tar.bz2 |
Reference-count the data used by PAC scripts, so it is shared between threads.
BUG=49396
Review URL: http://codereview.chromium.org/2836060
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@53095 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/proxy/init_proxy_resolver.h')
-rw-r--r-- | net/proxy/init_proxy_resolver.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/net/proxy/init_proxy_resolver.h b/net/proxy/init_proxy_resolver.h index ab1301a..814e932 100644 --- a/net/proxy/init_proxy_resolver.h +++ b/net/proxy/init_proxy_resolver.h @@ -57,7 +57,15 @@ class InitProxyResolver { STATE_SET_PAC_SCRIPT, STATE_SET_PAC_SCRIPT_COMPLETE, }; - typedef std::vector<GURL> UrlList; + + struct PacURL { + PacURL(bool auto_detect, const GURL& url) + : auto_detect(auto_detect), url(url) {} + bool auto_detect; + GURL url; + }; + + typedef std::vector<PacURL> UrlList; // Returns ordered list of PAC urls to try for |config|. UrlList BuildPacUrlsFallbackList(const ProxyConfig& config) const; @@ -83,7 +91,7 @@ class InitProxyResolver { State GetStartState() const; // Returns the current PAC URL we are fetching/testing. - const GURL& current_pac_url() const; + const PacURL& current_pac_url() const; void DidCompleteInit(); void Cancel(); |