Index: chrome/browser/chromeos/login/login_performer.cc |
diff --git a/chrome/browser/chromeos/login/login_performer.cc b/chrome/browser/chromeos/login/login_performer.cc |
index d22c84a48571f66e01391bc2ae7e95755ab05e23..1d578381f474abf0e260658b11b26486d5b9d212 100644 |
--- a/chrome/browser/chromeos/login/login_performer.cc |
+++ b/chrome/browser/chromeos/login/login_performer.cc |
@@ -20,11 +20,10 @@ |
#include "chrome/browser/chromeos/login/screen_locker.h" |
#include "chrome/browser/chromeos/login/user_manager.h" |
#include "chrome/browser/chromeos/policy/device_local_account_policy_service.h" |
+#include "chrome/browser/chromeos/profiles/profile_helper.h" |
#include "chrome/browser/chromeos/settings/cros_settings.h" |
#include "chrome/browser/chromeos/settings/cros_settings_names.h" |
#include "chrome/browser/policy/browser_policy_connector.h" |
-#include "chrome/browser/profiles/profile.h" |
-#include "chrome/browser/profiles/profile_manager.h" |
#include "chrome/common/chrome_notification_types.h" |
#include "chrome/common/pref_names.h" |
#include "chromeos/dbus/dbus_thread_manager.h" |
@@ -481,7 +480,7 @@ void LoginPerformer::ResolveScreenUnlocked() { |
void LoginPerformer::StartLoginCompletion() { |
DVLOG(1) << "Login completion started"; |
BootTimesLoader::Get()->AddLoginTimeMarker("AuthStarted", false); |
- Profile* profile = g_browser_process->profile_manager()->GetDefaultProfile(); |
+ Profile* profile = ProfileHelper::GetSigninProfile(); |
authenticator_ = LoginUtils::Get()->CreateAuthenticator(this); |
BrowserThread::PostTask( |
@@ -497,14 +496,7 @@ void LoginPerformer::StartLoginCompletion() { |
void LoginPerformer::StartAuthentication() { |
DVLOG(1) << "Auth started"; |
BootTimesLoader::Get()->AddLoginTimeMarker("AuthStarted", false); |
- Profile* profile; |
- { |
- // This should be the first place where GetDefaultProfile() is called with |
- // logged_in_ = true. This will trigger a call to Profile::CreateProfile() |
- // which requires IO access. |
- base::ThreadRestrictions::ScopedAllowIO allow_io; |
- profile = g_browser_process->profile_manager()->GetDefaultProfile(); |
- } |
+ Profile* profile = ProfileHelper::GetSigninProfile(); |
if (delegate_) { |
authenticator_ = LoginUtils::Get()->CreateAuthenticator(this); |
BrowserThread::PostTask( |