summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorstevenjb@google.com <stevenjb@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-19 22:52:35 +0000
committerstevenjb@google.com <stevenjb@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-04-19 22:52:35 +0000
commit47317494db5a0041f8a32ce4a654f8209166e96e (patch)
tree0645fe30e46c8fd18532e731f0b4beeea96b5744 /chrome
parent4989165972ff27ee66abd7e83b521db24593a3cc (diff)
downloadchromium_src-47317494db5a0041f8a32ce4a654f8209166e96e.zip
chromium_src-47317494db5a0041f8a32ce4a654f8209166e96e.tar.gz
chromium_src-47317494db5a0041f8a32ce4a654f8209166e96e.tar.bz2
Fix for blocked popups crash (issue 79777).
BUG=chromium:79777 TEST=See issue TBR=avi git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82176 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/blocked_content_container.cc12
-rw-r--r--chrome/browser/extensions/extension_host.cc4
2 files changed, 9 insertions, 7 deletions
diff --git a/chrome/browser/blocked_content_container.cc b/chrome/browser/blocked_content_container.cc
index 11226dfc..5b5ba08 100644
--- a/chrome/browser/blocked_content_container.cc
+++ b/chrome/browser/blocked_content_container.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -67,8 +67,10 @@ void BlockedContentContainer::LaunchForContents(TabContents* tab_contents) {
tab_contents->set_delegate(NULL);
// We needn't call WasRestored to change its status because the
// TabContents::AddNewContents will do it.
- owner_->AddNewContents(tab_contents, content.disposition, content.bounds,
- content.user_gesture);
+ owner_->AddOrBlockNewContents(tab_contents,
+ content.disposition,
+ content.bounds,
+ content.user_gesture);
break;
}
}
@@ -115,8 +117,8 @@ void BlockedContentContainer::AddNewContents(TabContents* source,
WindowOpenDisposition disposition,
const gfx::Rect& initial_position,
bool user_gesture) {
- owner_->AddNewContents(new_contents, disposition, initial_position,
- user_gesture);
+ owner_->AddOrBlockNewContents(
+ new_contents, disposition, initial_position, user_gesture);
}
void BlockedContentContainer::CloseContents(TabContents* source) {
diff --git a/chrome/browser/extensions/extension_host.cc b/chrome/browser/extensions/extension_host.cc
index 50e13c4..6af23f9 100644
--- a/chrome/browser/extensions/extension_host.cc
+++ b/chrome/browser/extensions/extension_host.cc
@@ -629,8 +629,8 @@ void ExtensionHost::ShowCreatedWindow(int route_id,
TabContents* associated_contents = associated_tab_contents();
if (associated_contents &&
associated_contents->profile() == contents->profile()) {
- associated_contents->AddNewContents(contents, disposition, initial_pos,
- user_gesture);
+ associated_contents->AddOrBlockNewContents(
+ contents, disposition, initial_pos, user_gesture);
return;
}