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

Unified Diff: chrome/browser/chromeos/login/login_utils.cc

Issue 599263002: easy-signin: Defer chrome restart until key ops finish. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: only defer restart Created 6 years, 3 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/browser/chromeos/login/session/user_session_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/login/login_utils.cc
diff --git a/chrome/browser/chromeos/login/login_utils.cc b/chrome/browser/chromeos/login/login_utils.cc
index 2684220bf2d20ebbf7d0d029602022587f582a49..80c76fa43b4ffec72bc79d40a387acc68f44f043 100644
--- a/chrome/browser/chromeos/login/login_utils.cc
+++ b/chrome/browser/chromeos/login/login_utils.cc
@@ -164,6 +164,10 @@ bool CanPerformEarlyRestart() {
if (controller->auth_mode() != LoginPerformer::AUTH_MODE_INTERNAL)
return false;
+ // No early restart if Easy unlock key needs to be updated.
+ if (UserSessionManager::GetInstance()->NeedsToUpdateEasyUnlockKeys())
+ return false;
+
return true;
}
@@ -453,6 +457,14 @@ void LoginUtilsImpl::OnRlzInitialized() {
#endif
void LoginUtilsImpl::AttemptRestart(Profile* profile) {
+ if (UserSessionManager::GetInstance()
+ ->CheckEasyUnlockKeyOps(
+ base::Bind(&LoginUtilsImpl::AttemptRestart,
+ base::Unretained(this),
+ profile))) {
+ return;
+ }
+
if (UserSessionManager::GetInstance()->GetSigninSessionRestoreStrategy() !=
OAuth2LoginManager::RESTORE_FROM_COOKIE_JAR) {
chrome::AttemptRestart();
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/session/user_session_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698