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

Unified Diff: third_party/WebKit/Source/core/html/parser/PreloadRequest.h

Issue 1561903002: Fix double resource request for script resources with integrity attr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Created 4 years, 11 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
Index: third_party/WebKit/Source/core/html/parser/PreloadRequest.h
diff --git a/third_party/WebKit/Source/core/html/parser/PreloadRequest.h b/third_party/WebKit/Source/core/html/parser/PreloadRequest.h
index 465e8ae7c209a0406d148a61475cf21929de30a0..684f20637078e69aed119c46e9ffb7cbf361520b 100644
--- a/third_party/WebKit/Source/core/html/parser/PreloadRequest.h
+++ b/third_party/WebKit/Source/core/html/parser/PreloadRequest.h
@@ -7,6 +7,7 @@
#include "core/fetch/ClientHintsPreferences.h"
#include "core/fetch/FetchRequest.h"
+#include "core/fetch/IntegrityMetadata.h"
#include "core/fetch/Resource.h"
#include "platform/CrossOriginAttributeValue.h"
#include "platform/weborigin/SecurityPolicy.h"
@@ -51,6 +52,14 @@ public:
bool isPreconnect() const { return m_requestType == RequestTypePreconnect; }
const ClientHintsPreferences& preferences() const { return m_clientHintsPreferences; }
ReferrerPolicy referrerPolicy() const { return m_referrerPolicy; }
+ void setIntegrityMetadata(const IntegrityMetadataSet& metadataSet)
+ {
+ m_integrityMetadata = metadataSet;
+ }
+ IntegrityMetadataSet integrityMetadata() const
sof 2016/01/06 07:38:13 Would (const IntegrityMetadataSet&) work as return
jww 2016/01/06 18:37:53 Done.
+ {
+ return m_integrityMetadata;
+ }
private:
PreloadRequest(const String& initiatorName,
@@ -92,6 +101,7 @@ private:
ClientHintsPreferences m_clientHintsPreferences;
RequestType m_requestType;
ReferrerPolicy m_referrerPolicy;
+ IntegrityMetadataSet m_integrityMetadata;
};
typedef Vector<OwnPtr<PreloadRequest>> PreloadRequestStream;

Powered by Google App Engine
This is Rietveld 408576698