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

Unified Diff: chrome/browser/tab_contents/navigation_controller.cc

Issue 18433: Fix a crasher in the interstitial pages (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/tab_contents/navigation_controller.cc
===================================================================
--- chrome/browser/tab_contents/navigation_controller.cc (revision 8302)
+++ chrome/browser/tab_contents/navigation_controller.cc (working copy)
@@ -1010,18 +1010,9 @@
contents->set_is_active(true);
active_contents_ = contents;
- if (from_contents && from_contents != contents) {
- if (from_contents->delegate())
- from_contents->delegate()->ReplaceContents(from_contents, contents);
+ if (from_contents && from_contents != contents && from_contents->delegate())
+ from_contents->delegate()->ReplaceContents(from_contents, contents);
- if (from_contents->type() != contents->type()) {
- // The entry we just discarded needed a different TabContents type. We no
- // longer need it but we can't destroy it just yet because the TabContents
- // is very likely involved in the current stack.
- ScheduleTabContentsCollection(from_contents->type());
- }
- }
-
NavigationEntry temp_entry(*pending_entry_);
if (!contents->NavigateToPendingEntry(reload))
DiscardNonCommittedEntries();
« 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