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

Unified Diff: chrome/browser/process_singleton_win.cc

Issue 982323002: Rendezvous to hung browser will again offer to kill it. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/process_singleton_win.cc
diff --git a/chrome/browser/process_singleton_win.cc b/chrome/browser/process_singleton_win.cc
index 439dfb23ecdda48e4e696c280966c1d39bbeea5a..82f3d4f5739e2282e196bee5a2de038e8d696df6 100644
--- a/chrome/browser/process_singleton_win.cc
+++ b/chrome/browser/process_singleton_win.cc
@@ -33,6 +33,7 @@
#include "chrome/common/chrome_switches.h"
#include "chrome/grit/chromium_strings.h"
#include "chrome/installer/util/wmi.h"
+#include "components/browser_watcher/exit_funnel_win.h"
#include "content/public/common/result_codes.h"
#include "net/base/escape.h"
#include "ui/base/l10n/l10n_util.h"
@@ -257,7 +258,9 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcess() {
remote_window_ = NULL;
return PROCESS_NONE;
case chrome::NOTIFY_WINDOW_HUNG:
- remote_window_ = NULL;
+ // Record a hung rendezvous event in this process' exit funnel.
+ browser_watcher::ExitFunnel::RecordSingleEvent(
+ chrome::kBrowserExitCodesRegistryPath, L"RendezvousToHungBrowser");
break;
}
@@ -286,6 +289,11 @@ ProcessSingleton::NotifyResult ProcessSingleton::NotifyOtherProcess() {
return PROCESS_NOTIFIED;
}
+ // Record the termination event in the hung process' exit funnel.
+ browser_watcher::ExitFunnel funnel;
+ if (funnel.Init(chrome::kBrowserExitCodesRegistryPath, process.Handle()))
+ funnel.RecordEvent(L"HungBrowserTerminated");
+
// Time to take action. Kill the browser process.
base::KillProcess(process.Handle(), content::RESULT_CODE_HUNG, true);
remote_window_ = NULL;
« no previous file with comments | « no previous file | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698