New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 809976 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug
Team-Security-UX



Sign in to add a comment

content_setting DCHECK(!primary_url.is_empty()) reached.

Project Member Reported by arthurso...@chromium.org, Feb 7 2018

Issue description

Chrome Version: M66 commit f225bcfe5ee31f9e2b0d35fb5cadc7f19bf32abe
OS: N/A (Linux)

What steps will reproduce the problem?
(1) Navigate using the OmniBox to: javascript:window.open("javascript:window.open('https://www.google.com')")
(2) Click on "enable popup"

What is the expected result?
N/A

What happens instead?
[145161:145161:0207/134818.455587:FATAL:host_content_settings_map.cc(152)] Check failed: !primary_url.is_empty(). 
#0 0x7f8e79deec2d base::debug::StackTrace::StackTrace()
#1 0x7f8e79ded11c base::debug::StackTrace::StackTrace()
#2 0x7f8e79e75cca logging::LogMessage::~LogMessage()
#3 0x55b6d1e386dc (anonymous namespace)::GetPatternsFromScopingType()
#4 0x55b6d1e3439f (anonymous namespace)::GetPatternsForContentSettingsType()
#5 0x55b6d1e34733 HostContentSettingsMap::GetNarrowestPatterns()
#6 0x55b6d1e3444e HostContentSettingsMap::CanSetNarrowestContentSetting()
#7 0x55b6d4d71e5b ContentSettingSingleRadioGroup::SetRadioGroup()
#8 0x55b6d4d6ff98 ContentSettingSingleRadioGroup::ContentSettingSingleRadioGroup()
#9 0x55b6d4d7236c ContentSettingPopupBubbleModel::ContentSettingPopupBubbleModel()
#10 0x55b6d4d7b900 ContentSettingBubbleModel::CreateContentSettingBubbleModel()
#11 0x55b6d4d65cec ContentSettingSimpleImageModel::CreateBubbleModelImpl()
#12 0x55b6d4d6ac6a ContentSettingImageModel::CreateBubbleModel()
#13 0x55b6d4d65262 ContentSettingImageView::ShowBubble()
#14 0x55b6d4d639b3 IconLabelBubbleView::OnActivate()
#15 0x55b6d4d63968 IconLabelBubbleView::NotifyClick()
#16 0x7f8e6c366116 views::Button::OnMouseReleased()
#17 0x7f8e6c45f672 views::View::ProcessMouseReleased()
#18 0x7f8e6c45f138 views::View::OnMouseEvent()
#19 0x7f8e6c338886 views::InkDropHostView::OnMouseEvent()
#20 0x7f8e6f8aec33 ui::EventHandler::OnEvent()
#21 0x7f8e6f8b8a3f ui::ScopedTargetHandler::OnEvent()
#22 0x7f8e6f8ad460 ui::EventDispatcher::DispatchEvent()
#23 0x7f8e6f8abc82 ui::EventDispatcher::ProcessEvent()
#24 0x7f8e6f8ab73f ui::EventDispatcherDelegate::DispatchEventToTarget()
#25 0x7f8e6f8ab5f3 ui::EventDispatcherDelegate::DispatchEvent()
#26 0x7f8e6c473c66 views::internal::RootView::OnMouseReleased()
#27 0x7f8e6c47d0bd views::Widget::OnMouseEvent()
#28 0x7f8e6c4b6c46 views::DesktopNativeWidgetAura::OnMouseEvent()
#29 0x7f8e6f8aec33 ui::EventHandler::OnEvent()
#30 0x7f8e6f8ad460 ui::EventDispatcher::DispatchEvent()
#31 0x7f8e6f8abc82 ui::EventDispatcher::ProcessEvent()
#32 0x7f8e6f8ab73f ui::EventDispatcherDelegate::DispatchEventToTarget()
#33 0x7f8e6f8ab5f3 ui::EventDispatcherDelegate::DispatchEvent()
#34 0x7f8e6f8b03eb ui::EventProcessor::OnEventFromSource()
#35 0x7f8e6f8b072c ui::EventProcessor::OnEventFromSource()
#36 0x7f8e6f8b2533 ui::EventSource::DeliverEventToSink()
#37 0x7f8e6f8b1d14 ui::EventSource::SendEventToSink()
#38 0x7f8e6c4e2fb9 views::DesktopWindowTreeHostX11::DispatchMouseEvent()

+CC lshang@ because you wrote this DCHECK in https://codereview.chromium.org/1767083004
+CC raymes@ FYI.
 
Description: Show this description

Comment 2 by raymes@chromium.org, Feb 12 2018

Cc: dcheng@chromium.org
Components: UI>Browser>Navigation
Owner: nasko@chromium.org
Status: Assigned (was: Untriaged)
We could check for this case but I'm worried that this is exposing some deeper issue. The problem is that currently if a website runs the following code:

window.open("javascript:window.open('https://www.google.com')")

A new tab is opened which displays "about:blank" in the omnibox, however WebContents::GetLastCommittedURL returns an empty GURL. I'm worried that behavior isn't correct.

nasko/dcheng: could you please help triage?

Comment 3 by nasko@chromium.org, Mar 19 2018

Cc: nasko@chromium.org
Owner: raymes@chromium.org
Actually, returning an empty GURL from GetLastCommittedURL is exactly the correct behavior in this case. One can argue that it is a bit surprising or unexpected, but that window has not really committed a navigation to any URL, therefore the returned value is invalid GURL.

Assigning over to raymes@ (as content_settings OWNER), since either the DCHECK needs to be changed or the callers of those methods need to account for the possibility of no committed navigations.

Comment 4 by raymes@chromium.org, Mar 20 2018

Components: -UI>Browser>Navigation
Thanks nasko - that's good to know. The right fix is to keep the DCHECK. We need to think about the behavior that we want in cases like this. I think we probably never want to show page action icons if web_contents->GetLastCommittedURL is empty. 

Comment 5 by raymes@chromium.org, Mar 25 2018

Components: -Internals>Permissions>Model UI>Browser>Permissions>Indicators
Owner: ----
Status: Available (was: Assigned)
Marking as available as I'm not longer working on permissions UI so this isn't a priority for me. 

Sign in to add a comment