Commit 7656b530 authored by shrikant@chromium.org's avatar shrikant@chromium.org

Fixing reopening of tabs after relaunch by preventing reentry into AttemptExit process.

TESTS=Please follow steps as outlined in the bug report.
R=cpu@chromium.org, ananta@chromium.org
BUG=318503

Review URL: https://codereview.chromium.org/102403004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@238467 0039d316-1c4b-4281-b951-d872f2087c98
parent 8b08f0ea
......@@ -10,6 +10,7 @@
#include "base/memory/ref_counted.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/browser_process_platform_part_aurawin.h"
#include "chrome/browser/browser_shutdown.h"
#include "chrome/browser/chrome_notification_types.h"
#include "chrome/browser/lifetime/application_lifetime.h"
#include "chrome/browser/profiles/profile_manager.h"
......@@ -79,8 +80,14 @@ void ChromeMetroViewerProcessHost::OnChannelError() {
aura::RemoteRootWindowHostWin::Instance()->Disconnected();
g_browser_process->ReleaseModule();
CloseOpenAshBrowsers();
chrome::CloseAsh();
// If browser is trying to quit, we shouldn't reenter the process.
// TODO(shrikant): In general there seem to be issues with how AttemptExit
// reentry works. In future release please clean up related code.
if (!browser_shutdown::IsTryingToQuit()) {
CloseOpenAshBrowsers();
chrome::CloseAsh();
}
// Tell the rest of Chrome about it.
content::NotificationService::current()->Notify(
chrome::NOTIFICATION_ASH_SESSION_ENDED,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment