Chromium Code Reviews| Index: chrome/browser/signin/signin_tracker.cc |
| diff --git a/chrome/browser/signin/signin_tracker.cc b/chrome/browser/signin/signin_tracker.cc |
| index cdddc4966590e381a1aeffda7c2072334b4b6b94..42cc54f0e5936712bcf2bcb983b1ca3244b9d4f0 100644 |
| --- a/chrome/browser/signin/signin_tracker.cc |
| +++ b/chrome/browser/signin/signin_tracker.cc |
| @@ -171,6 +171,10 @@ bool SigninTracker::AreServicesSignedIn(Profile* profile) { |
| return true; |
| ProfileSyncService* service = |
| ProfileSyncServiceFactory::GetForProfile(profile); |
| + // Check if sync disabled for domain flag was received from server. Don't care |
| + // about the sync state in this case. |
| + if (service->IsManaged()) |
|
Andrew T Wilson (Slow)
2013/05/24 15:13:10
Rather than making every caller of Profile::IsSync
pavely
2013/05/24 22:17:11
I tried this in my experiments. The issue is that
Andrew T Wilson (Slow)
2013/05/27 15:03:34
Yeah, that's a funky edge case. You could deal wit
|
| + return true; |
| return (service->IsSyncEnabledAndLoggedIn() && |
| service->IsSyncTokenAvailable() && |
| service->GetAuthError().state() == GoogleServiceAuthError::NONE && |
| @@ -195,6 +199,8 @@ SigninTracker::LoginState SigninTracker::GetSigninState( |
| // also. |
| ProfileSyncService* service = profile->IsSyncAccessible() ? |
| ProfileSyncServiceFactory::GetForProfile(profile) : NULL; |
| + if (service->IsManaged()) |
|
Andrew T Wilson (Slow)
2013/05/24 15:13:10
See my previous comment - if IsSyncAccessible() ca
|
| + service = NULL; |
| if (service && service->waiting_for_auth()) { |
| // Still waiting for an auth token to come in so stay in the INITIALIZING |
| // state (we do this to avoid triggering an early signin error in the case |