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

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

Issue 894843003: Move the RenderProcessGone IPC from RenderViewHost to RenderFrameHost (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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/renderer_host/render_view_host_impl.cc
diff --git a/content/browser/renderer_host/render_view_host_impl.cc b/content/browser/renderer_host/render_view_host_impl.cc
index 88e923b65dec4be81ee110138d164bf46d7debb7..cf0ac424f86fd4dac940bcd5012ef99be80fde82 100644
--- a/content/browser/renderer_host/render_view_host_impl.cc
+++ b/content/browser/renderer_host/render_view_host_impl.cc
@@ -886,7 +886,6 @@ bool RenderViewHostImpl::OnMessageReceived(const IPC::Message& msg) {
OnShowFullscreenWidget)
IPC_MESSAGE_HANDLER_DELAY_REPLY(ViewHostMsg_RunModal, OnRunModal)
IPC_MESSAGE_HANDLER(ViewHostMsg_RenderViewReady, OnRenderViewReady)
- IPC_MESSAGE_HANDLER(ViewHostMsg_RenderProcessGone, OnRenderProcessGone)
IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateState, OnUpdateState)
IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateTargetURL, OnUpdateTargetURL)
IPC_MESSAGE_HANDLER(ViewHostMsg_Close, OnClose)
@@ -907,6 +906,7 @@ bool RenderViewHostImpl::OnMessageReceived(const IPC::Message& msg) {
IPC_MESSAGE_HANDLER(ViewHostMsg_DidZoomURL, OnDidZoomURL)
IPC_MESSAGE_HANDLER(ViewHostMsg_RunFileChooser, OnRunFileChooser)
IPC_MESSAGE_HANDLER(ViewHostMsg_FocusedNodeTouched, OnFocusedNodeTouched)
+ IPC_MESSAGE_HANDLER(FrameHostMsg_RenderProcessGone, OnRenderProcessGone)
// Have the super handle all other messages.
IPC_MESSAGE_UNHANDLED(
handled = RenderWidgetHostImpl::OnMessageReceived(msg))
@@ -1051,22 +1051,8 @@ void RenderViewHostImpl::OnRenderViewReady() {
}
void RenderViewHostImpl::OnRenderProcessGone(int status, int exit_code) {
- // Keep the termination status so we can get at it later when we
- // need to know why it died.
- render_view_termination_status_ =
- static_cast<base::TerminationStatus>(status);
-
- // Reset frame tree state associated with this process. This must happen
- // before RenderViewTerminated because observers expect the subframes of any
- // affected frames to be cleared first.
- delegate_->GetFrameTree()->RenderProcessGone(this);
-
- // Our base class RenderWidgetHost needs to reset some stuff.
- RendererExited(render_view_termination_status_, exit_code);
-
- delegate_->RenderViewTerminated(this,
- static_cast<base::TerminationStatus>(status),
- exit_code);
+ // Do nothing, otherwise RenderWidgetHostImpl will assume it is not a
+ // RenderViewHostImpl and destroy itself.
Charlie Reis 2015/02/03 01:06:35 At some point, we'll need RenderWidgetHostImpl to
nasko 2015/02/04 16:51:31 Acknowledged.
}
void RenderViewHostImpl::OnUpdateState(int32 page_id, const PageState& state) {

Powered by Google App Engine
This is Rietveld 408576698