Inspecting slot fallback content on Document causes DCHECK() |
|||||||
Issue descriptionChrome Version: ToT (debug build) OS: Any Steps to reproduce: 1. Open attached file (document-slot.html) 2. Open inspector 3. Inspect slot element A <slot> element can have fallback content in Document tree (not in a shadow tree). Calling HTMLSlotElement::FirstDistributedNode() for such a slot will cause DCHECK() on this line: https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/html/HTMLSlotElement.h?type=cs&q=FirstDistributedNode&l=54 backtrace #0 0x7f949406535b base::debug::StackTrace::StackTrace() #1 0x7f949406405c base::debug::StackTrace::StackTrace() #2 0x7f9494064e6f base::debug::(anonymous namespace)::StackDumpSignalHandler() #3 0x7f94997a2330 <unknown> #4 0x7f948582dc37 gsignal #5 0x7f9485831028 abort #6 0x7f9494062056 base::debug::(anonymous namespace)::DebugBreak() #7 0x7f9494062038 base::debug::BreakDebugger() #8 0x7f94940d7bf4 logging::LogMessage::~LogMessage() #9 0x7f948bc229d6 blink::HTMLSlotElement::FirstDistributedNode() #10 0x7f948c25c54d blink::InspectorDOMAgent::BuildDistributedNodesForSlot() #11 0x7f948c254360 blink::InspectorDOMAgent::BuildObjectForNode() #12 0x7f948c25505e blink::InspectorDOMAgent::BuildArrayForContainerChildren() #13 0x7f948c254d1d blink::InspectorDOMAgent::PushChildNodesToFrontend() #14 0x7f948c25558f blink::InspectorDOMAgent::requestChildNodes() #15 0x7f948c2555f9 blink::InspectorDOMAgent::requestChildNodes() #16 0x7f948cf2d921 blink::protocol::DOM::DispatcherImpl::requestChildNodes() #17 0x7f948cf2c4b6 blink::protocol::DOM::DispatcherImpl::dispatch() #18 0x7f948cfc2222 blink::protocol::UberDispatcher::dispatch() #19 0x7f948c2d5532 blink::InspectorSession::DispatchProtocolMessage() #20 0x7f94897914c0 blink::WebDevToolsAgentImpl::DispatchMessageFromFrontend() #21 0x7f948979134e blink::WebDevToolsAgentImpl::DispatchOnInspectorBackend() #22 0x7f9496f8d80f content::DevToolsAgent::OnDispatchOnInspectorBackend()
,
May 26 2017
yuzus@, could you have a chance to take look? kochi@, help yuzus@ if needed.
,
Jul 11 2017
,
Aug 30 2017
elkurin@, could you check if this still happens, and if so, could you fix?
,
Oct 11 2017
The assigned owner "elkurin@google.com" is not able to receive e-mails, please re-triage. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Oct 12 2017
Rakina, this would be a good bug to learn about debugging Blink.
,
Oct 16 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b44ad5f753584eca237a6185a749d05ddec87209 commit b44ad5f753584eca237a6185a749d05ddec87209 Author: Rakina Zata Amni <rakina@chromium.org> Date: Mon Oct 16 04:59:15 2017 Check if slot is in a shadow tree before building its distributed nodes If you open a page with a slot that's not under a shadow tree and try to inspect that slot, it will crash because of a DCHECK when trying to build distributed nodes for that slot. Solution: Added a condition to check whether a slot is in a shadow tree or not before building distributed nodes for that slot. Bug: 715033 Change-Id: Ic778c1ebff95d6a035d2bb53932ac50761357beb Reviewed-on: https://chromium-review.googlesource.com/715976 Reviewed-by: Dmitry Gozman <dgozman@chromium.org> Reviewed-by: Takayoshi Kochi <kochi@chromium.org> Commit-Queue: Rakina Amni <rakina@chromium.org> Cr-Commit-Position: refs/heads/master@{#508985} [add] https://crrev.com/b44ad5f753584eca237a6185a749d05ddec87209/third_party/WebKit/LayoutTests/http/tests/devtools/elements/shadow/inspect-slot-not-in-shadow-tree-expected.txt [add] https://crrev.com/b44ad5f753584eca237a6185a749d05ddec87209/third_party/WebKit/LayoutTests/http/tests/devtools/elements/shadow/inspect-slot-not-in-shadow-tree.html [modify] https://crrev.com/b44ad5f753584eca237a6185a749d05ddec87209/third_party/WebKit/Source/core/inspector/InspectorDOMAgent.cpp
,
Oct 16 2017
|
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by hayato@chromium.org
, Apr 26 2017