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

Unified Diff: chrome/browser/ui/startup/startup_browser_creator.cc

Issue 1157273006: Fix the System Profile to not load extensions. It could otherwise be forced to by GPO. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2403
Patch Set: Created 5 years, 7 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 | « chrome/browser/ui/browser_command_controller.cc ('k') | chrome/test/base/testing_profile_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/startup/startup_browser_creator.cc
diff --git a/chrome/browser/ui/startup/startup_browser_creator.cc b/chrome/browser/ui/startup/startup_browser_creator.cc
index 82f182bb39d5ad8258840ca0900d60f37575a454..38cc153f64b02b303c24e3c0c13b89602e550bb3 100644
--- a/chrome/browser/ui/startup/startup_browser_creator.cc
+++ b/chrome/browser/ui/startup/startup_browser_creator.cc
@@ -682,15 +682,16 @@ bool StartupBrowserCreator::ProcessCmdLineImpl(
bool signin_required = profile_index != std::string::npos &&
profile_info.ProfileIsSigninRequiredAtIndex(profile_index);
- // Guest or locked profiles cannot be re-opened on startup. The only
- // exception is if there's already a Guest window open in a separate
+ // Guest, system or locked profiles cannot be re-opened on startup. The
+ // only exception is if there's already a Guest window open in a separate
// process (for example, launching a new browser after clicking on a
// downloaded file in Guest mode).
- bool has_guest_browsers = last_used_profile->IsGuestSession() &&
+ bool guest_or_system = last_used_profile->IsGuestSession() ||
+ last_used_profile->IsSystemProfile();
+ bool has_guest_browsers = guest_or_system &&
chrome::GetTotalBrowserCountForProfile(
last_used_profile->GetOffTheRecordProfile()) > 0;
- if (signin_required ||
- (last_used_profile->IsGuestSession() && !has_guest_browsers)) {
+ if (signin_required || (guest_or_system && !has_guest_browsers)) {
profiles::UserManagerProfileSelected action =
command_line.HasSwitch(switches::kShowAppList) ?
profiles::USER_MANAGER_SELECT_PROFILE_APP_LAUNCHER :
« no previous file with comments | « chrome/browser/ui/browser_command_controller.cc ('k') | chrome/test/base/testing_profile_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698