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

Side by Side Diff: trunk/src/content/browser/frame_host/frame_tree_node.cc

Issue 163703004: Revert 250823 "With --site-per-process, avoid a crash when a sub..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "content/browser/frame_host/frame_tree_node.h" 5 #include "content/browser/frame_host/frame_tree_node.h"
6 6
7 #include <queue> 7 #include <queue>
8 8
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "content/browser/frame_host/frame_tree.h" 10 #include "content/browser/frame_host/frame_tree.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 if ((*iter) == child) 65 if ((*iter) == child)
66 break; 66 break;
67 } 67 }
68 68
69 if (iter != children_.end()) { 69 if (iter != children_.end()) {
70 (*iter)->set_parent(NULL); 70 (*iter)->set_parent(NULL);
71 children_.erase(iter); 71 children_.erase(iter);
72 } 72 }
73 } 73 }
74 74
75 void FrameTreeNode::ResetForNewProcess() { 75 void FrameTreeNode::ResetForMainFrameSwap() {
76 frame_id_ = kInvalidFrameId; 76 frame_id_ = kInvalidFrameId;
77 current_url_ = GURL(); 77 current_url_ = GURL();
78 78
79 // The children may not have been cleared if a cross-process navigation 79 // The children may not have been cleared if a cross-process navigation
80 // commits before the old process cleans everything up. Make sure the child 80 // commits before the old process cleans everything up. Make sure the child
81 // nodes get deleted before swapping to a new process. 81 // nodes get deleted.
82 children_.clear(); 82 children_.clear();
83 } 83 }
84 84
85 } // namespace content 85 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698