Fix crash when calling LoadURL/Reload from OnRenderProcessTerminated (issue #1429).

git-svn-id: https://chromiumembedded.googlecode.com/svn/branches/2171@1972 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt 2015-01-13 17:40:36 +00:00
parent ce6a7583a2
commit 3240dbbb39
2 changed files with 30 additions and 0 deletions

View File

@ -138,6 +138,12 @@ patches = [
'name': 'ui_gl_81sdk',
'path': '../ui/gl/',
},
{
# Fix crash when calling LoadURL/Reload from OnRenderProcessTerminated.
# https://code.google.com/p/chromiumembedded/issues/detail?id=1429
'name': 'render_process_host_1429',
'path': '../content/browser/renderer_host/',
},
{
# Disable scollbar bounce and overlay on OS X.
# http://code.google.com/p/chromiumembedded/issues/detail?id=364

View File

@ -0,0 +1,24 @@
diff --git render_process_host_impl.cc render_process_host_impl.cc
index ef9570f..4dd5eb4 100644
--- render_process_host_impl.cc
+++ render_process_host_impl.cc
@@ -1927,6 +1927,9 @@ void RenderProcessHostImpl::ProcessDied(bool already_dead) {
message_port_message_filter_ = NULL;
RemoveUserData(kSessionStorageHolderKey);
+ mojo_application_host_.reset(new MojoApplicationHost);
+ mojo_activation_required_ = false;
+
IDMap<IPC::Listener>::iterator iter(&listeners_);
while (!iter.IsAtEnd()) {
iter.GetCurrentValue()->OnMessageReceived(
@@ -1936,9 +1939,6 @@ void RenderProcessHostImpl::ProcessDied(bool already_dead) {
iter.Advance();
}
- mojo_application_host_.reset(new MojoApplicationHost);
- mojo_activation_required_ = false;
-
// It's possible that one of the calls out to the observers might have caused
// this object to be no longer needed.
if (delayed_cleanup_needed_)