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

Unified Diff: content/renderer/render_frame_proxy.cc

Issue 1039403002: OOPIF: Remove the FrameTreeNode when a RemoteFrame is detached. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Disable ActiveTab test on FYI bot Created 5 years, 8 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 | « content/browser/site_per_process_browsertest.cc ('k') | testing/buildbot/chromium.fyi.json » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_frame_proxy.cc
diff --git a/content/renderer/render_frame_proxy.cc b/content/renderer/render_frame_proxy.cc
index ae6d699ae739783c76a70f4dcb05fcd246c45949..1523fb7356ad8116068df6344f65f923313efb1b 100644
--- a/content/renderer/render_frame_proxy.cc
+++ b/content/renderer/render_frame_proxy.cc
@@ -304,9 +304,14 @@ void RenderFrameProxy::OnDidUpdateName(const std::string& name) {
}
void RenderFrameProxy::frameDetached() {
- if (web_frame_->parent())
+ if (web_frame_->parent()) {
web_frame_->parent()->removeChild(web_frame_);
+ // Let the browser process know this subframe is removed, so that it is
+ // destroyed in its current process.
+ Send(new FrameHostMsg_Detach(routing_id_));
+ }
+
web_frame_->close();
delete this;
}
« no previous file with comments | « content/browser/site_per_process_browsertest.cc ('k') | testing/buildbot/chromium.fyi.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698