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

Unified Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 9751001: Don't allow a renderer to exit if we are using it in other views. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove test for now. Created 8 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/render_process_host_impl.cc
diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc
index 793163b8e8dfe93ce1eda3d97370d1e6ef31ad81..508228cf6cb383428f6fb3cc0223539a2ca59f02 100644
--- a/content/browser/renderer_host/render_process_host_impl.cc
+++ b/content/browser/renderer_host/render_process_host_impl.cc
@@ -1250,8 +1250,9 @@ void RenderProcessHostImpl::ProcessDied(base::ProcessHandle handle,
}
void RenderProcessHostImpl::OnShutdownRequest() {
- // Don't shutdown if there are pending RenderViews being swapped back in.
- if (pending_views_)
+ // Don't shut down if there are more RenderViews than the one asking to
+ // close, or if there are pending RenderViews being swapped back in.
+ if (pending_views_ || render_widget_hosts_.size() > 1)
return;
// Notify any tabs that might have swapped out renderers from this process.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698