Commit cec80c3d authored by droger@chromium.org's avatar droger@chromium.org

Query the network delegate for cookies even if there is no cookie monster

On iOS, there is a platform specific implementation of the cookie store which is not a CookieMonster.
However, the network delegate is currently only called if the cookie store is a CookieMonster, and thus cookie settings are bypassed.
This CL calls the network delegate even if the cookie store is not a CookieMonster.

BUG=145954

Review URL: https://chromiumcodereview.appspot.com/11417148

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@170942 0039d316-1c4b-4281-b951-d872f2087c98
parent e2dcc969
......@@ -731,10 +731,14 @@ class NET_EXPORT URLRequest : NON_EXPORTED_BASE(public base::NonThreadSafe),
void NotifyAuthRequiredComplete(NetworkDelegate::AuthRequiredResponse result);
void NotifyCertificateRequested(SSLCertRequestInfo* cert_request_info);
void NotifySSLCertificateError(const SSLInfo& ssl_info, bool fatal);
void NotifyReadCompleted(int bytes_read);
// These functions delegate to |network_delegate_| if it is not NULL.
// If |network_delegate_| is NULL, cookies can be used unless
// SetDefaultCookiePolicyToBlock() has been called.
bool CanGetCookies(const CookieList& cookie_list) const;
bool CanSetCookie(const std::string& cookie_line,
CookieOptions* options) const;
void NotifyReadCompleted(int bytes_read);
// Called when the delegate blocks or unblocks this request when intercepting
// certain requests.
......
......@@ -518,7 +518,7 @@ void URLRequestHttpJob::AddCookieHeaderAndStart() {
base::Bind(&URLRequestHttpJob::CheckCookiePolicyAndLoad,
weak_factory_.GetWeakPtr()));
} else {
DoLoadCookies();
CheckCookiePolicyAndLoad(CookieList());
}
} else {
DoStartTransaction();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment