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

Unified Diff: chrome/browser/metrics/chrome_stability_metrics_provider.cc

Issue 1320153002: Add new termination status for failed launch (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 | « no previous file | chrome/common/chrome_result_codes.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/metrics/chrome_stability_metrics_provider.cc
diff --git a/chrome/browser/metrics/chrome_stability_metrics_provider.cc b/chrome/browser/metrics/chrome_stability_metrics_provider.cc
index a26d263d3f6913906dcaef38f4e92358f05fdc64..e8bdd30fe3c90c9a9c9dd1b03979050edb02c146 100644
--- a/chrome/browser/metrics/chrome_stability_metrics_provider.cc
+++ b/chrome/browser/metrics/chrome_stability_metrics_provider.cc
@@ -14,6 +14,7 @@
#include "chrome/browser/browser_process.h"
#include "chrome/browser/chrome_notification_types.h"
#include "chrome/common/chrome_constants.h"
+#include "chrome/common/chrome_result_codes.h"
#include "chrome/common/pref_names.h"
#include "components/metrics/proto/system_profile.pb.h"
#include "content/public/browser/child_process_data.h"
@@ -66,7 +67,8 @@ int MapCrashExitCodeForHistogram(int exit_code) {
if (exit_code == STATUS_GUARD_PAGE_VIOLATION)
return 0x1FCF7EC3; // Randomly picked number.
#endif
-
+ if (exit_code == -1)
+ return chrome::RESULT_CODE_RENDERER_PROCESS_START_FAILURE;
return std::abs(exit_code);
}
@@ -279,7 +281,9 @@ void ChromeStabilityMetricsProvider::LogRendererCrash(
host->GetID());
#endif
if (status == base::TERMINATION_STATUS_PROCESS_CRASHED ||
- status == base::TERMINATION_STATUS_ABNORMAL_TERMINATION) {
+ status == base::TERMINATION_STATUS_ABNORMAL_TERMINATION ||
+ (status == base::TERMINATION_STATUS_PROCESS_WAS_KILLED &&
Alexei Svitkine (slow) 2015/08/28 16:45:50 Probably worth adding a unit test for - e.g. call
Will Harris 2015/09/01 01:15:38 Done.
+ exit_code == -1)) {
Will Harris 2015/08/28 16:41:11 reviewer note: this error code comes from RenderP
Alexei Svitkine (slow) 2015/08/28 16:45:50 Can this be made a constant that both places can r
Will Harris 2015/08/28 16:52:13 render_process_host_impl.cc is in content so I'd h
jam 2015/08/28 17:18:35 It seems a pseudo code can be in both modules. Sin
if (was_extension_process) {
IncrementPrefValue(prefs::kStabilityExtensionRendererCrashCount);
« no previous file with comments | « no previous file | chrome/common/chrome_result_codes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698