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

Unified Diff: content/renderer/render_frame_impl.cc

Issue 2252153002: Add crash keys to capture useful data for origin mismatch crashes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Register crash keys. Created 4 years, 4 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 | « chrome/common/crash_keys.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_frame_impl.cc
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index cb9e3d3faa5df2dc38de129057f07c3d243797bb..8adbbc631cc26e8f8dc605e316514e67580f5837 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -4771,6 +4771,16 @@ void RenderFrameImpl::SendDidCommitProvisionalLoad(
if (params.origin.scheme() != url::kFileScheme ||
!render_view_->GetWebkitPreferences()
.allow_universal_access_from_file_urls) {
+ base::debug::SetCrashKeyValue("origin_mismatch_url", params.url.spec());
+ base::debug::SetCrashKeyValue("origin_mismatch_origin",
+ params.origin.Serialize());
+ base::debug::SetCrashKeyValue("origin_mismatch_transition",
+ base::IntToString(params.transition));
+ base::debug::SetCrashKeyValue("origin_mismatch_redirects",
+ base::IntToString(params.redirects.size()));
+ base::debug::SetCrashKeyValue(
+ "origin_mismatch_same_page",
+ base::IntToString(params.was_within_same_page));
CHECK(params.origin.IsSameOriginWith(url::Origin(params.url)))
<< " url:" << params.url << " origin:" << params.origin;
}
« no previous file with comments | « chrome/common/crash_keys.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698