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

Unified Diff: chrome/browser/chromeos/login/login_utils.cc

Issue 16998003: Update CrOS to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 6 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/chromeos/login/login_utils.cc
diff --git a/chrome/browser/chromeos/login/login_utils.cc b/chrome/browser/chromeos/login/login_utils.cc
index b96563636549e6ca8a6c372ec7416a80b39ddd3f..1006b08679815fa4ff7b96d2d76529db7844edca 100644
--- a/chrome/browser/chromeos/login/login_utils.cc
+++ b/chrome/browser/chromeos/login/login_utils.cc
@@ -498,7 +498,7 @@ void LoginUtilsImpl::CompleteProfileCreate(Profile* user_profile) {
void LoginUtilsImpl::RestoreAuthSession(Profile* user_profile,
bool restore_from_auth_cookies) {
- CHECK((authenticator_ && authenticator_->authentication_profile()) ||
+ CHECK((authenticator_.get() && authenticator_->authentication_profile()) ||
!restore_from_auth_cookies);
if (!login_manager_.get())
return;
@@ -514,9 +514,9 @@ void LoginUtilsImpl::RestoreAuthSession(Profile* user_profile,
// all other tokens and user_context.
login_manager_->RestoreSession(
user_profile,
- authenticator_ && authenticator_->authentication_profile() ?
- authenticator_->authentication_profile()->GetRequestContext() :
- NULL,
+ authenticator_.get() && authenticator_->authentication_profile()
+ ? authenticator_->authentication_profile()->GetRequestContext()
+ : NULL,
session_restore_strategy_,
oauth2_refresh_token_,
user_context_.auth_code);
@@ -722,12 +722,12 @@ scoped_refptr<Authenticator> LoginUtilsImpl::CreateAuthenticator(
LoginStatusConsumer* consumer) {
// Screen locker needs new Authenticator instance each time.
if (ScreenLocker::default_screen_locker()) {
- if (authenticator_)
+ if (authenticator_.get())
authenticator_->SetConsumer(NULL);
authenticator_ = NULL;
}
- if (authenticator_ == NULL) {
+ if (authenticator_.get() == NULL) {
authenticator_ = new ParallelAuthenticator(consumer);
} else {
// TODO(nkostylev): Fix this hack by improving Authenticator dependencies.
« no previous file with comments | « chrome/browser/chromeos/login/login_performer.cc ('k') | chrome/browser/chromeos/login/oauth2_login_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698