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

Unified Diff: chrome/browser/signin/chrome_signin_client.cc

Issue 2478173003: Lock profile before sign in when force sign in is enabled. (Closed)
Patch Set: rogerta's comments Created 4 years, 1 month 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
Index: chrome/browser/signin/chrome_signin_client.cc
diff --git a/chrome/browser/signin/chrome_signin_client.cc b/chrome/browser/signin/chrome_signin_client.cc
index 3d823cc5a5cf0d803e9c192547c582e761314550..0b6764d252a267d27d7aced2e6831a3999062d4d 100644
--- a/chrome/browser/signin/chrome_signin_client.cc
+++ b/chrome/browser/signin/chrome_signin_client.cc
@@ -432,7 +432,7 @@ void ChromeSigninClient::OnCloseBrowsersSuccess(
const base::FilePath& profile_path) {
SigninClient::PreSignOut(sign_out);
- LockProfile(profile_path);
+ LockForceSigninProfile(profile_path);
// After sign out, lock the profile and show UserManager if necessary.
if (should_display_user_manager_) {
ShowUserManager(profile_path);
@@ -446,7 +446,8 @@ void ChromeSigninClient::OnCloseBrowsersAborted(
should_display_user_manager_ = true;
}
-void ChromeSigninClient::LockProfile(const base::FilePath& profile_path) {
+void ChromeSigninClient::LockForceSigninProfile(
+ const base::FilePath& profile_path) {
ProfileAttributesEntry* entry;
bool has_entry =
g_browser_process->profile_manager()
@@ -454,7 +455,7 @@ void ChromeSigninClient::LockProfile(const base::FilePath& profile_path) {
.GetProfileAttributesWithPath(profile_->GetPath(), &entry);
if (!has_entry)
return;
- entry->SetIsSigninRequired(true);
+ entry->LockForceSigninProfile(true);
}
void ChromeSigninClient::ShowUserManager(const base::FilePath& profile_path) {
« no previous file with comments | « chrome/browser/signin/chrome_signin_client.h ('k') | chrome/browser/signin/chrome_signin_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698