diff options
author | jamescook@chromium.org <jamescook@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-10 15:33:53 +0000 |
---|---|---|
committer | jamescook@chromium.org <jamescook@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-10 15:33:53 +0000 |
commit | 5f19571f496e421ff45352fc8ec4a157bf8f631a (patch) | |
tree | e8410e86c8b5dac08de50368b567bb760dc10d72 | |
parent | 9b4b4e0703d8e92107d4f6cc62ddb732838cc3fa (diff) | |
download | chromium_src-5f19571f496e421ff45352fc8ec4a157bf8f631a.zip chromium_src-5f19571f496e421ff45352fc8ec4a157bf8f631a.tar.gz chromium_src-5f19571f496e421ff45352fc8ec4a157bf8f631a.tar.bz2 |
Don't make sad tab view for normal renderer termination
We noticed some of the statistics for Tabs.SadTab.CrashCreated were much higher than expected on R19. Something changed that caused us to create a SadTabView every time a tab was closed, even if the renderer exited normally. This patch skips the creation of the SadTabView for normal termination status.
BUG=126507
TEST=manual, opened and closed tabs manually and verified about:histograms Tabs.SadTab.CrashCreated does not go up, also tested killing tabs with task manager and kill -11 to the renderer process to verify that sad tabs still work in those cases
Review URL: https://chromiumcodereview.appspot.com/10388062
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@136310 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/ui/sad_tab_helper.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/chrome/browser/ui/sad_tab_helper.cc b/chrome/browser/ui/sad_tab_helper.cc index 491862b..88f74de 100644 --- a/chrome/browser/ui/sad_tab_helper.cc +++ b/chrome/browser/ui/sad_tab_helper.cc @@ -41,6 +41,10 @@ void SadTabHelper::RenderViewGone(base::TerminationStatus status) { if (browser_shutdown::GetShutdownType() != browser_shutdown::NOT_VALID) return; + // Don't build the sad tab view when the termination status is normal. + if (status == base::TERMINATION_STATUS_NORMAL_TERMINATION) + return; + if (HasSadTab()) return; |