Index: chrome/browser/chromeos/login/session/user_session_manager.cc |
diff --git a/chrome/browser/chromeos/login/session/user_session_manager.cc b/chrome/browser/chromeos/login/session/user_session_manager.cc |
index 0a145993d8c347da68a2f27d5198852ce6fd6ee2..64d4bac2c02605d8dd792e30e7ffad42d3995727 100644 |
--- a/chrome/browser/chromeos/login/session/user_session_manager.cc |
+++ b/chrome/browser/chromeos/login/session/user_session_manager.cc |
@@ -33,6 +33,7 @@ |
#include "chrome/browser/browser_shutdown.h" |
#include "chrome/browser/chrome_notification_types.h" |
#include "chrome/browser/chromeos/accessibility/accessibility_manager.h" |
+#include "chrome/browser/chromeos/arc/arc_auth_service.h" |
#include "chrome/browser/chromeos/base/locale_util.h" |
#include "chrome/browser/chromeos/boot_times_recorder.h" |
#include "chrome/browser/chromeos/first_run/first_run.h" |
@@ -1145,6 +1146,7 @@ void UserSessionManager::FinalizePrepareProfile(Profile* profile) { |
DCHECK(arc::ArcServiceManager::Get()); |
arc::ArcServiceManager::Get()->OnPrimaryUserProfilePrepared( |
multi_user_util::GetAccountIdFromProfile(profile)); |
+ arc::ArcAuthService::Get()->SetProfile(profile); |
xiyuan
2016/01/26 23:37:05
nit: Prefer to have something similar to ArcServic
khmel
2016/01/27 22:36:21
Sounds better, thanks
|
} |
} |
@@ -1785,6 +1787,11 @@ bool UserSessionManager::TokenHandlesEnabled() { |
} |
void UserSessionManager::Shutdown() { |
+ if (arc::ArcBridgeService::GetEnabled( |
+ base::CommandLine::ForCurrentProcess())) { |
+ DCHECK(arc::ArcServiceManager::Get()); |
+ arc::ArcAuthService::Get()->SetProfile(nullptr); |
xiyuan
2016/01/26 23:37:05
nit: Similarly, prefer to have something like ArcS
khmel
2016/01/27 22:36:21
Done.
|
+ } |
token_handle_fetcher_.reset(); |
token_handle_util_.reset(); |
first_run::GoodiesDisplayer::Delete(); |