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

Unified Diff: content/browser/web_contents/render_view_host_manager.cc

Issue 18512004: Cleanup swapped out RenderViewHosts when the process goes away. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed whitespace Created 7 years, 5 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: content/browser/web_contents/render_view_host_manager.cc
diff --git a/content/browser/web_contents/render_view_host_manager.cc b/content/browser/web_contents/render_view_host_manager.cc
index ed674d5c90592252e3345ecba9780f7e0698fa3f..1148951a2cdea0982bb677ae28cab8ccb4ab6e9f 100644
--- a/content/browser/web_contents/render_view_host_manager.cc
+++ b/content/browser/web_contents/render_view_host_manager.cc
@@ -88,6 +88,8 @@ void RenderViewHostManager::Init(BrowserContext* browser_context,
site_instance)));
// Keep track of renderer processes as they start to shut down.
nasko 2013/07/10 17:29:00 nit: Update the comment to include that we track c
Fady Samuel 2013/07/10 17:51:33 Done.
+ registrar_.Add(this, NOTIFICATION_RENDERER_PROCESS_CLOSED,
+ NotificationService::AllSources());
registrar_.Add(this, NOTIFICATION_RENDERER_PROCESS_CLOSING,
NotificationService::AllSources());
}
@@ -397,6 +399,7 @@ void RenderViewHostManager::Observe(
const NotificationSource& source,
const NotificationDetails& details) {
switch (type) {
+ case NOTIFICATION_RENDERER_PROCESS_CLOSED:
case NOTIFICATION_RENDERER_PROCESS_CLOSING:
RendererProcessClosing(
Source<RenderProcessHost>(source).ptr());

Powered by Google App Engine
This is Rietveld 408576698