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

Unified Diff: content/child/resource_dispatcher.cc

Issue 264613006: Move first-party cookie URL logic to browser process. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 7 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 | « content/child/resource_dispatcher.h ('k') | content/child/resource_dispatcher_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/child/resource_dispatcher.cc
diff --git a/content/child/resource_dispatcher.cc b/content/child/resource_dispatcher.cc
index 9e6e923d9661cc0853d55c1900caea941a058e68..66169d249aeec79c43259a93f7a4725a01e5f0b2 100644
--- a/content/child/resource_dispatcher.cc
+++ b/content/child/resource_dispatcher.cc
@@ -486,6 +486,7 @@ void ResourceDispatcher::OnDownloadedData(int request_id,
void ResourceDispatcher::OnReceivedRedirect(
int request_id,
const GURL& new_url,
+ const GURL& new_first_party_for_cookies,
const ResourceResponseHead& response_head) {
TRACE_EVENT0("loader", "ResourceDispatcher::OnReceivedRedirect");
PendingRequestInfo* request_info = GetPendingRequestInfo(request_id);
@@ -493,13 +494,10 @@ void ResourceDispatcher::OnReceivedRedirect(
return;
request_info->response_start = ConsumeIOTimestamp();
- bool has_new_first_party_for_cookies = false;
- GURL new_first_party_for_cookies;
ResourceResponseInfo renderer_response_info;
ToResourceResponseInfo(*request_info, response_head, &renderer_response_info);
- if (request_info->peer->OnReceivedRedirect(new_url, renderer_response_info,
- &has_new_first_party_for_cookies,
- &new_first_party_for_cookies)) {
+ if (request_info->peer->OnReceivedRedirect(
+ new_url, new_first_party_for_cookies, renderer_response_info)) {
// Double-check if the request is still around. The call above could
// potentially remove it.
request_info = GetPendingRequestInfo(request_id);
@@ -509,9 +507,7 @@ void ResourceDispatcher::OnReceivedRedirect(
// SiteIsolationPolicy later when OnReceivedResponse is called.
request_info->response_url = new_url;
request_info->pending_redirect_message.reset(
- new ResourceHostMsg_FollowRedirect(request_id,
- has_new_first_party_for_cookies,
- new_first_party_for_cookies));
+ new ResourceHostMsg_FollowRedirect(request_id));
if (!request_info->is_deferred) {
FollowPendingRedirect(request_id, *request_info);
}
« no previous file with comments | « content/child/resource_dispatcher.h ('k') | content/child/resource_dispatcher_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698