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

Side by Side Diff: chrome/app/chrome_crash_reporter_client_win.cc

Issue 2123073002: Switch chrome_elf exception handling from breakpad to crashpad (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased to tip and git cl format Created 4 years, 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/app/chrome_exe_main_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // TODO(ananta/scottmg) 5 // TODO(ananta/scottmg)
6 // Add test coverage for Crashpad. 6 // Add test coverage for Crashpad.
7 #include "chrome/app/chrome_crash_reporter_client_win.h" 7 #include "chrome/app/chrome_crash_reporter_client_win.h"
8 8
9 #include <assert.h> 9 #include <assert.h>
10 #include <windows.h> 10 #include <windows.h>
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 va_start(arguments, format); 65 va_start(arguments, format);
66 int result = vsnprintf(buffer, size, format, arguments); 66 int result = vsnprintf(buffer, size, format, arguments);
67 va_end(arguments); 67 va_end(arguments);
68 return result; 68 return result;
69 } 69 }
70 70
71 size_t RegisterCrashKeysHelper() { 71 size_t RegisterCrashKeysHelper() {
72 // The following keys may be chunked by the underlying crash logging system, 72 // The following keys may be chunked by the underlying crash logging system,
73 // but ultimately constitute a single key-value pair. 73 // but ultimately constitute a single key-value pair.
74 // 74 //
75 // If you're adding keys here, please also add them to the list in 75 // For now these need to be kept relatively up to date with those in
76 // //chrome/common/crash_keys.cc::RegisterChromeCrashKeys() and
76 // //blimp/engine/app/blimp_engine_crash_keys.cc 77 // //blimp/engine/app/blimp_engine_crash_keys.cc
77 constexpr base::debug::CrashKey fixed_keys[] = { 78 constexpr base::debug::CrashKey fixed_keys[] = {
78 {kMetricsClientId, kSmallSize}, 79 {kMetricsClientId, kSmallSize},
79 {kChannel, kSmallSize}, 80 {kChannel, kSmallSize},
80 {kActiveURL, kLargeSize}, 81 {kActiveURL, kLargeSize},
81 {kNumVariations, kSmallSize}, 82 {kNumVariations, kSmallSize},
82 {kVariations, kLargeSize}, 83 {kVariations, kLargeSize},
83 {kNumExtensionsCount, kSmallSize}, 84 {kNumExtensionsCount, kSmallSize},
84 {kShutdownType, kSmallSize}, 85 {kShutdownType, kSmallSize},
85 {kGPUVendorID, kSmallSize}, 86 {kGPUVendorID, kSmallSize},
86 {kGPUDeviceID, kSmallSize}, 87 {kGPUDeviceID, kSmallSize},
87 {kGPUDriverVersion, kSmallSize}, 88 {kGPUDriverVersion, kSmallSize},
88 {kGPUPixelShaderVersion, kSmallSize}, 89 {kGPUPixelShaderVersion, kSmallSize},
89 {kGPUVertexShaderVersion, kSmallSize}, 90 {kGPUVertexShaderVersion, kSmallSize},
90 91
91 // content/: 92 // content/:
93 {"bad_message_reason", kSmallSize},
92 {"discardable-memory-allocated", kSmallSize}, 94 {"discardable-memory-allocated", kSmallSize},
93 {"discardable-memory-free", kSmallSize}, 95 {"discardable-memory-free", kSmallSize},
94 {kFontKeyName, kSmallSize}, 96 {kFontKeyName, kSmallSize},
95 {"ppapi_path", kMediumSize}, 97 {"ppapi_path", kMediumSize},
96 {"subresource_url", kLargeSize}, 98 {"subresource_url", kLargeSize},
97 {"total-discardable-memory-allocated", kSmallSize}, 99 {"total-discardable-memory-allocated", kSmallSize},
98 {kBug464926CrashKey, kSmallSize}, 100 {kBug464926CrashKey, kSmallSize},
99 {kViewCount, kSmallSize}, 101 {kViewCount, kSmallSize},
100 102
101 // media/: 103 // media/:
102 {kHungAudioThreadDetails, kSmallSize}, 104 {kHungAudioThreadDetails, kSmallSize},
103 {kZeroEncodeDetails, kSmallSize}, 105 {kZeroEncodeDetails, kSmallSize},
104 106
107 // gin/:
108 {"v8-ignition", kSmallSize},
109
105 // Temporary for http://crbug.com/575245. 110 // Temporary for http://crbug.com/575245.
106 {"swapout_frame_id", kSmallSize}, 111 {"swapout_frame_id", kSmallSize},
107 {"swapout_proxy_id", kSmallSize}, 112 {"swapout_proxy_id", kSmallSize},
108 {"swapout_view_id", kSmallSize}, 113 {"swapout_view_id", kSmallSize},
109 {"commit_frame_id", kSmallSize}, 114 {"commit_frame_id", kSmallSize},
110 {"commit_proxy_id", kSmallSize}, 115 {"commit_proxy_id", kSmallSize},
111 {"commit_view_id", kSmallSize}, 116 {"commit_view_id", kSmallSize},
112 {"commit_main_render_frame_id", kSmallSize}, 117 {"commit_main_render_frame_id", kSmallSize},
113 {"newproxy_proxy_id", kSmallSize}, 118 {"newproxy_proxy_id", kSmallSize},
114 {"newproxy_view_id", kSmallSize}, 119 {"newproxy_view_id", kSmallSize},
(...skipping 14 matching lines...) Expand all
129 {"initrf_parent_is_in_same_site_instance", kSmallSize}, 134 {"initrf_parent_is_in_same_site_instance", kSmallSize},
130 {"initrf_parent_process_is_live", kSmallSize}, 135 {"initrf_parent_process_is_live", kSmallSize},
131 {"initrf_root_is_in_same_site_instance", kSmallSize}, 136 {"initrf_root_is_in_same_site_instance", kSmallSize},
132 {"initrf_root_is_in_same_site_instance_as_parent", kSmallSize}, 137 {"initrf_root_is_in_same_site_instance_as_parent", kSmallSize},
133 {"initrf_root_process_is_live", kSmallSize}, 138 {"initrf_root_process_is_live", kSmallSize},
134 {"initrf_root_proxy_is_live", kSmallSize}, 139 {"initrf_root_proxy_is_live", kSmallSize},
135 140
136 // Temporary for https://crbug.com/612711. 141 // Temporary for https://crbug.com/612711.
137 {"aci_wrong_sp_extension_id", kSmallSize}, 142 {"aci_wrong_sp_extension_id", kSmallSize},
138 143
144 // Temporary for http://crbug.com/621730
145 {"postmessage_src_origin", kMediumSize},
146 {"postmessage_dst_origin", kMediumSize},
147 {"postmessage_dst_url", kLargeSize},
148 {"postmessage_script_info", kLargeSize},
149
139 // Temporary for https://crbug.com/616149. 150 // Temporary for https://crbug.com/616149.
140 {"existing_extension_pref_value_type", crash_keys::kSmallSize}, 151 {"existing_extension_pref_value_type", crash_keys::kSmallSize},
152
153 // Temporary for https://crbug.com/625040
154 {"swdh_not_handled_message_type", crash_keys::kMediumSize},
155 {"swdh_not_handled_worker_status", crash_keys::kMediumSize},
141 }; 156 };
142 157
143 // This dynamic set of keys is used for sets of key value pairs when gathering 158 // This dynamic set of keys is used for sets of key value pairs when gathering
144 // a collection of data, like command line switches or extension IDs. 159 // a collection of data, like command line switches or extension IDs.
145 std::vector<base::debug::CrashKey> keys(fixed_keys, 160 std::vector<base::debug::CrashKey> keys(fixed_keys,
146 fixed_keys + arraysize(fixed_keys)); 161 fixed_keys + arraysize(fixed_keys));
147 162
148 crash_keys::GetCrashKeysForCommandLineSwitches(&keys); 163 crash_keys::GetCrashKeysForCommandLineSwitches(&keys);
149 164
150 // Register the extension IDs. 165 // Register the extension IDs.
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 bool ChromeCrashReporterClient::GetCollectStatsConsent() { 346 bool ChromeCrashReporterClient::GetCollectStatsConsent() {
332 return install_static::GetCollectStatsConsent(); 347 return install_static::GetCollectStatsConsent();
333 } 348 }
334 349
335 bool ChromeCrashReporterClient::EnableBreakpadForProcess( 350 bool ChromeCrashReporterClient::EnableBreakpadForProcess(
336 const std::string& process_type) { 351 const std::string& process_type) {
337 return process_type == install_static::kRendererProcess || 352 return process_type == install_static::kRendererProcess ||
338 process_type == install_static::kPpapiPluginProcess || 353 process_type == install_static::kPpapiPluginProcess ||
339 process_type == install_static::kGpuProcess; 354 process_type == install_static::kGpuProcess;
340 } 355 }
OLDNEW
« no previous file with comments | « no previous file | chrome/app/chrome_exe_main_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698