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

Unified Diff: content/child/resource_dispatcher.cc

Issue 398903002: Plumb redirect info out of net, through content, and into child processes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: darin comments Created 6 years, 4 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 3ca9668c246a0a3fca0bc7ab1d6bee6275f9ed82..c8fe61af5c2a0d3de35024c8ead92bd4c4e4a9ce 100644
--- a/content/child/resource_dispatcher.cc
+++ b/content/child/resource_dispatcher.cc
@@ -499,8 +499,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 net::RedirectInfo& redirect_info,
const ResourceResponseHead& response_head) {
TRACE_EVENT0("loader", "ResourceDispatcher::OnReceivedRedirect");
PendingRequestInfo* request_info = GetPendingRequestInfo(request_id);
@@ -510,8 +509,8 @@ void ResourceDispatcher::OnReceivedRedirect(
ResourceResponseInfo renderer_response_info;
ToResourceResponseInfo(*request_info, response_head, &renderer_response_info);
- if (request_info->peer->OnReceivedRedirect(
- new_url, new_first_party_for_cookies, renderer_response_info)) {
+ if (request_info->peer->OnReceivedRedirect(redirect_info,
+ renderer_response_info)) {
// Double-check if the request is still around. The call above could
// potentially remove it.
request_info = GetPendingRequestInfo(request_id);
@@ -519,7 +518,7 @@ void ResourceDispatcher::OnReceivedRedirect(
return;
// We update the response_url here so that we can send it to
// SiteIsolationPolicy later when OnReceivedResponse is called.
- request_info->response_url = new_url;
+ request_info->response_url = redirect_info.new_url;
request_info->pending_redirect_message.reset(
new ResourceHostMsg_FollowRedirect(request_id));
if (!request_info->is_deferred) {
« 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