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

Unified Diff: webkit/plugins/ppapi/ppb_url_request_info_impl.cc

Issue 7046091: Fix problems with PPB_URLLoader_Impl and PPAPITests.URLLoader. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 6 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 | « webkit/plugins/ppapi/ppb_url_loader_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppb_url_request_info_impl.cc
===================================================================
--- webkit/plugins/ppapi/ppb_url_request_info_impl.cc (revision 89290)
+++ webkit/plugins/ppapi/ppb_url_request_info_impl.cc (working copy)
@@ -382,8 +382,10 @@
if (has_custom_referrer_url_) {
if (!custom_referrer_url_.empty())
frame->setReferrerForRequest(web_request, GURL(custom_referrer_url_));
- } else {
- frame->setReferrerForRequest(web_request, WebURL()); // Use default.
+ } else if (!allow_cross_origin_requests_) {
+ // Use default, except for cross-origin requests, since 'referer' is not
+ // whitelisted and will cause the request to fail.
+ frame->setReferrerForRequest(web_request, WebURL());
}
if (has_custom_content_transfer_encoding_) {
« no previous file with comments | « webkit/plugins/ppapi/ppb_url_loader_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698