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

Unified Diff: content/renderer/content_security_policy_util.cc

Issue 2761153003: PlzNavigate & CSP. Use the SourceLocation in violation reports. (Closed)
Patch Set: Addressed comment @alexmos Created 3 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
Index: content/renderer/content_security_policy_util.cc
diff --git a/content/renderer/content_security_policy_util.cc b/content/renderer/content_security_policy_util.cc
index 5ba788760015b4b48f3d87f42350ffa4bce1693c..9f1ae7194add66f308ffef410a2abefb04642341 100644
--- a/content/renderer/content_security_policy_util.cc
+++ b/content/renderer/content_security_policy_util.cc
@@ -70,6 +70,12 @@ blink::WebContentSecurityPolicyViolation BuildWebContentSecurityPolicyViolation(
violation.header = blink::WebString::fromASCII(violation_params.header);
violation.disposition = violation_params.disposition;
violation.afterRedirect = violation_params.after_redirect;
+ violation.sourceLocation.url =
+ blink::WebString::fromLatin1(violation_params.source_location.url);
+ violation.sourceLocation.lineNumber =
+ violation_params.source_location.line_number;
+ violation.sourceLocation.columnNumber =
+ violation_params.source_location.column_number;
return violation;
}
« no previous file with comments | « content/common/frame_messages.h ('k') | third_party/WebKit/LayoutTests/FlagExpectations/enable-browser-side-navigation » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698