Index: chrome/browser/profiles/profile_manager.cc |
diff --git a/chrome/browser/profiles/profile_manager.cc b/chrome/browser/profiles/profile_manager.cc |
index 1eceba98853543353e672a8d1e1245fdb9160bc2..4ea4b0a3dd4e9418f1bd4e718a8a57477cc14b9c 100644 |
--- a/chrome/browser/profiles/profile_manager.cc |
+++ b/chrome/browser/profiles/profile_manager.cc |
@@ -993,6 +993,7 @@ void ProfileManager::DoFinalInit(Profile* profile, bool go_off_the_record) { |
void ProfileManager::DoFinalInitForServices(Profile* profile, |
bool go_off_the_record) { |
#if defined(ENABLE_EXTENSIONS) |
+ ProfileInfoCache& cache = GetProfileInfoCache(); |
extensions::ExtensionSystem::Get(profile)->InitForRegularProfile( |
!go_off_the_record); |
// During tests, when |profile| is an instance of TestingProfile, |
@@ -1001,6 +1002,15 @@ void ProfileManager::DoFinalInitForServices(Profile* profile, |
extensions::ExtensionSystem::Get(profile)->extension_service()-> |
RegisterContentSettings(profile->GetHostContentSettingsMap()); |
} |
+ // Set the block extensions bit on the ExtensionService. There likely are no |
+ // blockable extensions to block. |
+ if (!profile->IsGuestSession() && |
+ cache.ProfileIsSigninRequiredAtIndex( |
noms (inactive)
2014/11/13 15:24:54
nit: can cache.Profile...( go on the previous line
Mike Lerman
2014/11/13 15:30:05
Done.
|
+ cache.GetIndexOfProfileWithPath(profile->GetPath()))) { |
+ extensions::ExtensionSystem::Get(profile)->extension_service()-> |
+ BlockAllExtensions(); |
+ } |
+ |
#endif |
#if defined(ENABLE_MANAGED_USERS) && !defined(OS_ANDROID) |
// Initialization needs to happen after extension system initialization (for |