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

Unified Diff: chrome/browser/spellchecker/spellcheck_service.cc

Issue 2063863002: Use DCHECKs when observing only a single notification. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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/spellchecker/spellcheck_service.cc
diff --git a/chrome/browser/spellchecker/spellcheck_service.cc b/chrome/browser/spellchecker/spellcheck_service.cc
index a7ba7ce6c8079f29f0d1cfd198d51b9785743d01..d21e463e7feff492ef69a4e9543c6a7b6cdf4abd 100644
--- a/chrome/browser/spellchecker/spellcheck_service.cc
+++ b/chrome/browser/spellchecker/spellcheck_service.cc
@@ -262,10 +262,8 @@ bool SpellcheckService::UnloadExternalDictionary(
void SpellcheckService::Observe(int type,
const content::NotificationSource& source,
const content::NotificationDetails& details) {
- DCHECK(type == content::NOTIFICATION_RENDERER_PROCESS_CREATED);
- content::RenderProcessHost* process =
- content::Source<content::RenderProcessHost>(source).ptr();
- InitForRenderer(process);
+ DCHECK_EQ(content::NOTIFICATION_RENDERER_PROCESS_CREATED, type);
+ InitForRenderer(content::Source<content::RenderProcessHost>(source).ptr());
}
void SpellcheckService::OnCustomDictionaryLoaded() {
« no previous file with comments | « chrome/browser/service_process/service_process_control.cc ('k') | chrome/browser/ssl/captive_portal_metrics_recorder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698