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

Unified Diff: chrome/browser/sync/profile_sync_service.cc

Issue 14630003: signin: move SigninManagerBase::Signout to SigninManager. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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
Index: chrome/browser/sync/profile_sync_service.cc
diff --git a/chrome/browser/sync/profile_sync_service.cc b/chrome/browser/sync/profile_sync_service.cc
index 14312e58e9aa3bfc0bb48bf6130569684a01f269..a1481b1093e2642f10b48db32636bdb46fd70164 100644
--- a/chrome/browser/sync/profile_sync_service.cc
+++ b/chrome/browser/sync/profile_sync_service.cc
@@ -1045,9 +1045,18 @@ void ProfileSyncService::OnStopSyncingPermanently() {
UpdateAuthErrorState(AuthError(AuthError::SERVICE_UNAVAILABLE));
sync_prefs_.SetStartSuppressed(true);
DisableForUser();
- // If signout is allowed, signout the user on a dashboard clear.
+
+ // Signout doesn't exist as a concept on Chrome OS. It currently does
+ // on other auto-start platforms (like Android, though we should probably
+ // use SigninManagerBase there as well), but we don't want to sign the
+ // user out on auto-start platforms if sync was disabled.
+ // TODO(tim): Platform specific refactoring here is bug 237866.
+#if !defined(OS_CHROMEOS)
+ SigninManager* signin = SigninManagerFactory::GetForProfile(profile_);
+
if (!auto_start_enabled_) // Skip signout on ChromeOS/Android.
- signin_->SignOut();
+ signin->SignOut();
+#endif
}
void ProfileSyncService::OnPassphraseRequired(

Powered by Google App Engine
This is Rietveld 408576698