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

Unified Diff: chrome/browser/sync/test/integration/sync_extension_helper.cc

Issue 16290004: Update chrome/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
Index: chrome/browser/sync/test/integration/sync_extension_helper.cc
diff --git a/chrome/browser/sync/test/integration/sync_extension_helper.cc b/chrome/browser/sync/test/integration/sync_extension_helper.cc
index 7f8fcabb3b938ff41e63f4ff143e0c797def8464..151020bde468948ed83970309d77576db98d19bc 100644
--- a/chrome/browser/sync/test/integration/sync_extension_helper.cc
+++ b/chrome/browser/sync/test/integration/sync_extension_helper.cc
@@ -61,13 +61,15 @@ void SyncExtensionHelper::SetupIfNecessary(SyncTest* test) {
std::string SyncExtensionHelper::InstallExtension(
Profile* profile, const std::string& name, Manifest::Type type) {
scoped_refptr<Extension> extension = GetExtension(profile, name, type);
- if (!extension) {
+ if (!extension.get()) {
NOTREACHED() << "Could not install extension " << name;
return std::string();
}
- profile->GetExtensionService()->OnExtensionInstalled(
- extension, syncer::StringOrdinal(), false /* no requirement errors */,
- false /* don't wait for idle to install */);
+ profile->GetExtensionService()
+ ->OnExtensionInstalled(extension.get(),
+ syncer::StringOrdinal(),
+ false /* no requirement errors */,
+ false /* don't wait for idle to install */);
return extension->id();
}
@@ -321,7 +323,7 @@ scoped_refptr<Extension> CreateExtension(const base::FilePath& base_dir,
ADD_FAILURE() << error;
return NULL;
}
- if (!extension) {
+ if (!extension.get()) {
ADD_FAILURE();
return NULL;
}
@@ -357,7 +359,7 @@ scoped_refptr<Extension> SyncExtensionHelper::GetExtension(
scoped_refptr<Extension> extension =
CreateExtension(profile->GetExtensionService()->install_directory(),
name, type);
- if (!extension) {
+ if (!extension.get()) {
ADD_FAILURE();
return NULL;
}

Powered by Google App Engine
This is Rietveld 408576698