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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 892463005: Revert "Fix MojoApplicationHost assertion when navigating from RenderProcessGone." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Represents the browser side of the browser <--> renderer communication 5 // Represents the browser side of the browser <--> renderer communication
6 // channel. There will be one RenderProcessHost per renderer process. 6 // channel. There will be one RenderProcessHost per renderer process.
7 7
8 #include "content/browser/renderer_host/render_process_host_impl.h" 8 #include "content/browser/renderer_host/render_process_host_impl.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 2057 matching lines...) Expand 10 before | Expand all | Expand 10 after
2068 RenderProcessExited(this, status, exit_code)); 2068 RenderProcessExited(this, status, exit_code));
2069 within_process_died_observer_ = false; 2069 within_process_died_observer_ = false;
2070 2070
2071 gpu_message_filter_ = NULL; 2071 gpu_message_filter_ = NULL;
2072 message_port_message_filter_ = NULL; 2072 message_port_message_filter_ = NULL;
2073 #if defined(ENABLE_BROWSER_CDMS) 2073 #if defined(ENABLE_BROWSER_CDMS)
2074 browser_cdm_manager_ = NULL; 2074 browser_cdm_manager_ = NULL;
2075 #endif 2075 #endif
2076 RemoveUserData(kSessionStorageHolderKey); 2076 RemoveUserData(kSessionStorageHolderKey);
2077 2077
2078 // RenderProcessGone handlers might navigate or perform other actions that
2079 // require a connection. Ensure that there is one before calling them.
2080 mojo_application_host_.reset(new MojoApplicationHost);
2081
2082 IDMap<IPC::Listener>::iterator iter(&listeners_); 2078 IDMap<IPC::Listener>::iterator iter(&listeners_);
2083 while (!iter.IsAtEnd()) { 2079 while (!iter.IsAtEnd()) {
2084 iter.GetCurrentValue()->OnMessageReceived( 2080 iter.GetCurrentValue()->OnMessageReceived(
2085 FrameHostMsg_RenderProcessGone(iter.GetCurrentKey(), 2081 FrameHostMsg_RenderProcessGone(iter.GetCurrentKey(),
2086 static_cast<int>(status), 2082 static_cast<int>(status),
2087 exit_code)); 2083 exit_code));
2088 iter.Advance(); 2084 iter.Advance();
2089 } 2085 }
2090 2086
2087 mojo_application_host_.reset(new MojoApplicationHost);
2088
2091 // It's possible that one of the calls out to the observers might have caused 2089 // It's possible that one of the calls out to the observers might have caused
2092 // this object to be no longer needed. 2090 // this object to be no longer needed.
2093 if (delayed_cleanup_needed_) 2091 if (delayed_cleanup_needed_)
2094 Cleanup(); 2092 Cleanup();
2095 2093
2096 // This object is not deleted at this point and might be reused later. 2094 // This object is not deleted at this point and might be reused later.
2097 // TODO(darin): clean this up 2095 // TODO(darin): clean this up
2098 } 2096 }
2099 2097
2100 int RenderProcessHostImpl::GetActiveViewCount() { 2098 int RenderProcessHostImpl::GetActiveViewCount() {
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
2400 if (worker_ref_count_ == 0) 2398 if (worker_ref_count_ == 0)
2401 Cleanup(); 2399 Cleanup();
2402 } 2400 }
2403 2401
2404 void RenderProcessHostImpl::GetAudioOutputControllers( 2402 void RenderProcessHostImpl::GetAudioOutputControllers(
2405 const GetAudioOutputControllersCallback& callback) const { 2403 const GetAudioOutputControllersCallback& callback) const {
2406 audio_renderer_host()->GetOutputControllers(callback); 2404 audio_renderer_host()->GetOutputControllers(callback);
2407 } 2405 }
2408 2406
2409 } // namespace content 2407 } // namespace content
OLDNEW
« 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