summaryrefslogtreecommitdiffstats
path: root/net/url_request
diff options
context:
space:
mode:
authorwillchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-12 05:54:06 +0000
committerwillchan@chromium.org <willchan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-12 05:54:06 +0000
commit70b923496d2efe796adb5b714be06a72447fb35f (patch)
treee6304ccf384bb4dc9b64d36375cf22a91d2b3f2e /net/url_request
parentd7a7173f296d9511ca33f77295c18fa3375d5573 (diff)
downloadchromium_src-70b923496d2efe796adb5b714be06a72447fb35f.zip
chromium_src-70b923496d2efe796adb5b714be06a72447fb35f.tar.gz
chromium_src-70b923496d2efe796adb5b714be06a72447fb35f.tar.bz2
Reland fix for OCSP startup race.
This is a revert of r62107 which is a revert of r62105 which is a revert of r60753 which is a revert of r60739 which is a revert of r60025 which is a revert of r59972 which is a revert of r59570 which is a revert of r59511 which is a revert of r59299 which is a revert of r59289. The most recent reverts have all been due to ChromiumOS leaks which I believe to be fixed after fixing bug 58572, since I tested the combined fix in r62105 which was green on all ChromiumOS valgrind bots. BUG=55940 TEST=Run a debug build on Linux. 10% or so of startups used to crash on startup. Shouldn't happen anymore. Review URL: http://codereview.chromium.org/3660010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@62256 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/url_request')
-rw-r--r--net/url_request/url_request_context.cc3
-rw-r--r--net/url_request/url_request_context.h8
2 files changed, 10 insertions, 1 deletions
diff --git a/net/url_request/url_request_context.cc b/net/url_request/url_request_context.cc
index 329f83f..518d43a 100644
--- a/net/url_request/url_request_context.cc
+++ b/net/url_request/url_request_context.cc
@@ -16,7 +16,8 @@ URLRequestContext::URLRequestContext()
http_auth_handler_factory_(NULL),
network_delegate_(NULL),
cookie_policy_(NULL),
- transport_security_state_(NULL) {
+ transport_security_state_(NULL),
+ is_main_(false) {
}
const std::string& URLRequestContext::GetUserAgent(const GURL& url) const {
diff --git a/net/url_request/url_request_context.h b/net/url_request/url_request_context.h
index 96de77d..bbbae67 100644
--- a/net/url_request/url_request_context.h
+++ b/net/url_request/url_request_context.h
@@ -109,6 +109,11 @@ class URLRequestContext
referrer_charset_ = charset;
}
+ // Controls whether or not the URLRequestContext considers itself to be the
+ // "main" URLRequestContext.
+ bool is_main() const { return is_main_; }
+ void set_is_main(bool is_main) { is_main_ = is_main; }
+
protected:
friend class base::RefCountedThreadSafe<URLRequestContext>;
@@ -137,6 +142,9 @@ class URLRequestContext
std::string referrer_charset_;
private:
+ // Indicates whether or not this is the main URLRequestContext.
+ bool is_main_;
+
DISALLOW_COPY_AND_ASSIGN(URLRequestContext);
};