summaryrefslogtreecommitdiffstats
path: root/chrome/common
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/common')
-rw-r--r--chrome/common/render_messages_internal.h3
-rw-r--r--chrome/common/resource_dispatcher.cc3
-rw-r--r--chrome/common/resource_dispatcher_unittest.cc6
-rw-r--r--chrome/common/security_filter_peer.cc1
-rw-r--r--chrome/common/security_filter_peer.h1
5 files changed, 11 insertions, 3 deletions
diff --git a/chrome/common/render_messages_internal.h b/chrome/common/render_messages_internal.h
index 552d4cd..6da2ec7 100644
--- a/chrome/common/render_messages_internal.h
+++ b/chrome/common/render_messages_internal.h
@@ -1054,8 +1054,9 @@ IPC_BEGIN_MESSAGES(ViewHost)
// Follows a redirect that occured for the resource request with the ID given
// as the parameter.
- IPC_MESSAGE_ROUTED2(ViewHostMsg_FollowRedirect,
+ IPC_MESSAGE_ROUTED3(ViewHostMsg_FollowRedirect,
int /* request_id */,
+ bool /* has_new_first_party_for_cookies */,
GURL /* new_first_party_for_cookies */)
// Makes a synchronous resource request via the browser.
diff --git a/chrome/common/resource_dispatcher.cc b/chrome/common/resource_dispatcher.cc
index ed0365a..5639f77 100644
--- a/chrome/common/resource_dispatcher.cc
+++ b/chrome/common/resource_dispatcher.cc
@@ -421,11 +421,14 @@ void ResourceDispatcher::OnReceivedRedirect(
RESOURCE_LOG("Dispatching redirect for " <<
request_info.peer->GetURLForDebugging().possibly_invalid_spec());
+ bool has_new_first_party_for_cookies = false;
GURL new_first_party_for_cookies;
if (request_info.peer->OnReceivedRedirect(new_url, info,
+ &has_new_first_party_for_cookies,
&new_first_party_for_cookies)) {
message_sender()->Send(
new ViewHostMsg_FollowRedirect(message.routing_id(), request_id,
+ has_new_first_party_for_cookies,
new_first_party_for_cookies));
} else {
CancelPendingRequest(message.routing_id(), request_id);
diff --git a/chrome/common/resource_dispatcher_unittest.cc b/chrome/common/resource_dispatcher_unittest.cc
index 1652ad9..ab12eea 100644
--- a/chrome/common/resource_dispatcher_unittest.cc
+++ b/chrome/common/resource_dispatcher_unittest.cc
@@ -35,8 +35,9 @@ class TestRequestCallback : public ResourceLoaderBridge::Peer {
virtual bool OnReceivedRedirect(
const GURL& new_url,
const ResourceLoaderBridge::ResponseInfo& info,
+ bool* has_new_first_party_for_cookies,
GURL* new_first_party_for_cookies) {
- *new_first_party_for_cookies = GURL();
+ *has_new_first_party_for_cookies = false;
return true;
}
@@ -246,8 +247,9 @@ class DeferredResourceLoadingTest : public ResourceDispatcherTest,
virtual bool OnReceivedRedirect(
const GURL& new_url,
const ResourceLoaderBridge::ResponseInfo& info,
+ bool* has_new_first_party_for_cookies,
GURL* new_first_party_for_cookies) {
- *new_first_party_for_cookies = GURL();
+ *has_new_first_party_for_cookies = false;
return true;
}
diff --git a/chrome/common/security_filter_peer.cc b/chrome/common/security_filter_peer.cc
index 6b2b427..02f0042 100644
--- a/chrome/common/security_filter_peer.cc
+++ b/chrome/common/security_filter_peer.cc
@@ -107,6 +107,7 @@ void SecurityFilterPeer::OnUploadProgress(uint64 position, uint64 size) {
bool SecurityFilterPeer::OnReceivedRedirect(
const GURL& new_url,
const webkit_glue::ResourceLoaderBridge::ResponseInfo& info,
+ bool* has_new_first_party_for_cookies,
GURL* new_first_party_for_cookies) {
NOTREACHED();
return false;
diff --git a/chrome/common/security_filter_peer.h b/chrome/common/security_filter_peer.h
index 3bd4fcf..c3d3513 100644
--- a/chrome/common/security_filter_peer.h
+++ b/chrome/common/security_filter_peer.h
@@ -42,6 +42,7 @@ class SecurityFilterPeer : public webkit_glue::ResourceLoaderBridge::Peer {
virtual bool OnReceivedRedirect(
const GURL& new_url,
const webkit_glue::ResourceLoaderBridge::ResponseInfo& info,
+ bool* has_new_first_party_for_cookies,
GURL* new_first_party_for_cookies);
virtual void OnReceivedResponse(
const webkit_glue::ResourceLoaderBridge::ResponseInfo& info,