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

Unified Diff: webkit/tools/test_shell/simple_resource_loader_bridge.cc

Issue 405011: Use an explicit boolean has_new_first_party_for_cookies instead... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Upload before checkin Created 11 years, 1 month 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 | « webkit/glue/weburlloader_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/tools/test_shell/simple_resource_loader_bridge.cc
===================================================================
--- webkit/tools/test_shell/simple_resource_loader_bridge.cc (revision 32257)
+++ webkit/tools/test_shell/simple_resource_loader_bridge.cc (working copy)
@@ -153,12 +153,14 @@
void NotifyReceivedRedirect(const GURL& new_url,
const ResourceLoaderBridge::ResponseInfo& info) {
+ bool has_new_first_party_for_cookies = false;
GURL new_first_party_for_cookies;
if (peer_ && peer_->OnReceivedRedirect(new_url, info,
+ &has_new_first_party_for_cookies,
&new_first_party_for_cookies)) {
io_thread->message_loop()->PostTask(FROM_HERE, NewRunnableMethod(
this, &RequestProxy::AsyncFollowDeferredRedirect,
- new_first_party_for_cookies));
+ has_new_first_party_for_cookies, new_first_party_for_cookies));
} else {
Cancel();
}
@@ -241,12 +243,13 @@
Done();
}
- void AsyncFollowDeferredRedirect(const GURL& new_first_party_for_cookies) {
+ void AsyncFollowDeferredRedirect(bool has_new_first_party_for_cookies,
+ const GURL& new_first_party_for_cookies) {
// This can be null in cases where the request is already done.
if (!request_.get())
return;
- if (!new_first_party_for_cookies.is_empty())
+ if (has_new_first_party_for_cookies)
request_->set_first_party_for_cookies(new_first_party_for_cookies);
request_->FollowDeferredRedirect();
}
« no previous file with comments | « webkit/glue/weburlloader_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698