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

Unified Diff: chrome/browser/search_engines/template_url_service.cc

Issue 10065016: [protector] Refactoring of --no-protector code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Mock fix Created 8 years, 8 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/search_engines/template_url_service.cc
diff --git a/chrome/browser/search_engines/template_url_service.cc b/chrome/browser/search_engines/template_url_service.cc
index abdd54826cf44f6b6152dfdfee7c47c85b4eda7d..22813e5606ca95a02084ca938a981c8ee8d6dd16 100644
--- a/chrome/browser/search_engines/template_url_service.cc
+++ b/chrome/browser/search_engines/template_url_service.cc
@@ -672,12 +672,11 @@ void TemplateURLService::OnWebDataServiceRequestDone(
protector::ProtectorServiceFactory::GetForProfile(profile());
DCHECK(protector_service);
protector_service->ShowChange(change.release());
- } else {
+ } else if (service_.get()) {
sky 2012/04/13 15:56:22 I don't think it's possible for service_ to be NUL
Ivan Korotkov 2012/04/13 17:19:10 You're right apparently. I was confused by another
sky 2012/04/13 21:33:39 yes
Ivan Korotkov 2012/04/13 22:06:32 Done.
// Protector is turned off: set the current default search to itself
// to update the backup and sign it. Otherwise, change will be reported
// every time when keywords are loaded until a search provider is added.
- // Note that this saves the default search provider to prefs.
- SetDefaultSearchProviderNoNotify(default_search_provider_);
+ service_->SetDefaultSearchProvider(default_search_provider_);
}
}
#endif

Powered by Google App Engine
This is Rietveld 408576698