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

Unified Diff: Source/core/html/HTMLLinkElement.cpp

Issue 199733008: Revert of HTML Imports: Send credentials for same origin requests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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 | « Source/core/fetch/ResourceLoader.cpp ('k') | Source/core/html/imports/HTMLImportsController.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLLinkElement.cpp
diff --git a/Source/core/html/HTMLLinkElement.cpp b/Source/core/html/HTMLLinkElement.cpp
index 09090654a5a551a637101969c43b849f5858fe9d..09d7978407ba205c56c5fc7c533bda8ad0a8d7ac 100644
--- a/Source/core/html/HTMLLinkElement.cpp
+++ b/Source/core/html/HTMLLinkElement.cpp
@@ -692,8 +692,10 @@
// Load stylesheets that are not needed for the rendering immediately with low priority.
FetchRequest request = builder.build(blocking);
AtomicString crossOriginMode = m_owner->fastGetAttribute(HTMLNames::crossoriginAttr);
- if (!crossOriginMode.isNull())
- request.setCrossOriginAccessControl(document().securityOrigin(), crossOriginMode);
+ if (!crossOriginMode.isNull()) {
+ StoredCredentials allowCredentials = equalIgnoringCase(crossOriginMode, "use-credentials") ? AllowStoredCredentials : DoNotAllowStoredCredentials;
+ request.setCrossOriginAccessControl(document().securityOrigin(), allowCredentials);
+ }
setResource(document().fetcher()->fetchCSSStyleSheet(request));
if (!resource()) {
« no previous file with comments | « Source/core/fetch/ResourceLoader.cpp ('k') | Source/core/html/imports/HTMLImportsController.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698