Closed Bug 1415683 Opened 7 years ago Closed 7 years ago

Assertion failure: supportedLists.Contains(aListID) (unexpected child list), at /src/layout/generic/nsGridContainerFrame.cpp:6807

Categories

(Core :: Layout, defect, P4)

defect

Tracking

()

RESOLVED FIXED
mozilla58
Tracking Status
firefox-esr52 --- wontfix
firefox56 --- wontfix
firefox57 --- wontfix
firefox58 --- fixed

People

(Reporter: tsmith, Assigned: MatsPalmgren_bugz)

References

(Blocks 1 open bug)

Details

(Keywords: assertion, testcase)

Attachments

(3 files)

Attached file testcase.html (deleted) —
Assertion failure: supportedLists.Contains(aListID) (unexpected child list), at /src/layout/generic/nsGridContainerFrame.cpp:6807 #0 nsGridContainerFrame::SetInitialChildList(mozilla::layout::FrameChildListID, nsFrameList&) /src/layout/generic/nsGridContainerFrame.cpp:6807:3 #1 nsFrameConstructorState::ConstructBackdropFrameFor(nsIContent*, nsIFrame*) /src/layout/base/nsCSSFrameConstructor.cpp:1314:10 #2 nsFrameConstructorState::AddChild(nsIFrame*, nsFrameItems&, nsIContent*, nsStyleContext*, nsContainerFrame*, bool, bool, bool, bool, nsIFrame*) /src/layout/base/nsCSSFrameConstructor.cpp:1367:7 #3 nsCSSFrameConstructor::ConstructFrameFromItemInternal(nsCSSFrameConstructor::FrameConstructionItem&, nsFrameConstructorState&, nsContainerFrame*, nsFrameItems&) /src/layout/base/nsCSSFrameConstructor.cpp:4142:12 #4 nsCSSFrameConstructor::ConstructFramesFromItem(nsFrameConstructorState&, nsCSSFrameConstructor::FrameConstructionItemList::Iterator&, nsContainerFrame*, nsFrameItems&) /src/layout/base/nsCSSFrameConstructor.cpp:6384:3 #5 nsCSSFrameConstructor::ConstructFramesFromItemList(nsFrameConstructorState&, nsCSSFrameConstructor::FrameConstructionItemList&, nsContainerFrame*, bool, nsFrameItems&) /src/layout/base/nsCSSFrameConstructor.cpp:11003:5 #6 nsCSSFrameConstructor::ContentRangeInserted(nsIContent*, nsIContent*, nsIContent*, nsILayoutHistoryState*, nsCSSFrameConstructor::InsertionKind, TreeMatchContext*) /src/layout/base/nsCSSFrameConstructor.cpp:8379:3 #7 nsCSSFrameConstructor::RecreateFramesForContent(nsIContent*, nsCSSFrameConstructor::InsertionKind) /src/layout/base/nsCSSFrameConstructor.cpp:10039:9 #8 mozilla::RestyleManager::ProcessRestyledFrames(nsStyleChangeList&) /src/layout/base/RestyleManager.cpp:1513:25 #9 mozilla::ServoRestyleManager::DoProcessPendingRestyles(mozilla::ServoTraversalFlags) /src/layout/base/ServoRestyleManager.cpp:1159:9 #10 mozilla::PresShell::DoFlushPendingNotifications(mozilla::ChangesToFlush) /src/layout/base/PresShell.cpp:4196:41 #11 nsRefreshDriver::Tick(long, mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:1882:18 #12 mozilla::RefreshDriverTimer::TickRefreshDrivers(long, mozilla::TimeStamp, nsTArray<RefPtr<nsRefreshDriver> >&) /src/layout/base/nsRefreshDriver.cpp:306:7 #13 mozilla::RefreshDriverTimer::Tick(long, mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:328:5 #14 mozilla::VsyncRefreshDriverTimer::RunRefreshDrivers(mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:769:5 #15 mozilla::VsyncRefreshDriverTimer::RefreshDriverVsyncObserver::TickRefreshDriver(mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:682:35 #16 mozilla::VsyncRefreshDriverTimer::RefreshDriverVsyncObserver::NotifyVsync(mozilla::TimeStamp) /src/layout/base/nsRefreshDriver.cpp:583:9 #17 mozilla::layout::VsyncChild::RecvNotify(mozilla::TimeStamp const&) /src/layout/ipc/VsyncChild.cpp:68:16 #18 mozilla::layout::PVsyncChild::OnMessageReceived(IPC::Message const&) /src/obj-firefox/ipc/ipdl/PVsyncChild.cpp:155:20 #19 mozilla::ipc::PBackgroundChild::OnMessageReceived(IPC::Message const&) /src/obj-firefox/ipc/ipdl/PBackgroundChild.cpp:1815:28 #20 mozilla::ipc::MessageChannel::DispatchAsyncMessage(IPC::Message const&) /src/ipc/glue/MessageChannel.cpp:2119:25 #21 mozilla::ipc::MessageChannel::DispatchMessage(IPC::Message&&) /src/ipc/glue/MessageChannel.cpp:2049:17 #22 mozilla::ipc::MessageChannel::RunMessage(mozilla::ipc::MessageChannel::MessageTask&) /src/ipc/glue/MessageChannel.cpp:1895:5 #23 mozilla::ipc::MessageChannel::MessageTask::Run() /src/ipc/glue/MessageChannel.cpp:1928:15 #24 nsThread::ProcessNextEvent(bool, bool*) /src/xpcom/threads/nsThread.cpp:1037:14 #25 NS_ProcessNextEvent(nsIThread*, bool) /src/xpcom/threads/nsThreadUtils.cpp:513:10 #26 mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) /src/ipc/glue/MessagePump.cpp:125:5 #27 MessageLoop::RunInternal() /src/ipc/chromium/src/base/message_loop.cc:326:10 #28 MessageLoop::Run() /src/ipc/chromium/src/base/message_loop.cc:299:3 #29 nsBaseAppShell::Run() /src/widget/nsBaseAppShell.cpp:158:27 #30 XRE_RunAppShell() /src/toolkit/xre/nsEmbedFunctions.cpp:877:22 #31 mozilla::ipc::MessagePumpForChildProcess::Run(base::MessagePump::Delegate*) /src/ipc/glue/MessagePump.cpp:269:9 #32 MessageLoop::RunInternal() /src/ipc/chromium/src/base/message_loop.cc:326:10 #33 MessageLoop::Run() /src/ipc/chromium/src/base/message_loop.cc:299:3 #34 XRE_InitChildProcess(int, char**, XREChildData const*) /src/toolkit/xre/nsEmbedFunctions.cpp:703:34 #35 content_process_main(mozilla::Bootstrap*, int, char**) /src/browser/app/../../ipc/contentproc/plugin-container.cpp:63:30 #36 main /src/browser/app/nsBrowserApp.cpp:280:18 #37 __libc_start_main /build/glibc-bfm8X4/glibc-2.23/csu/../csu/libc-start.c:291 #38 _start (firefox+0x41ebe4)
Flags: in-testsuite?
Attached file prefs.js (deleted) —
Goes back more than a year, which is as far back as mozregression can bisect debug builds.
Has Regression Range: --- → no
Version: 58 Branch → Trunk
Why are we trying to add children to a nsGridContainerFrame on a kBackdropList? What are the frames on this list? AFAICT, only ViewportFrame has code that actually does something with the frames on it. http://searchfox.org/mozilla-central/search?q=kBackdropList
Blocks: 1236828
Component: CSS Parsing and Computation → Layout
Flags: needinfo?(xidorn+moz)
Attachment #8926573 - Attachment mime type: application/x-javascript → text/javascript
Frame of any HTML element can get a ::backdrop pseudo-element when it goes to fullscreen, and kBackdropList is for storing the placeholder of a BackdropFrame, which is the frame of ::backdrop pseudo-element. nsContainerFrame handles kBackdropList, and subclasses should just handle that to nsContainerFrame. In general, I don't think subclasses should put assumption on what frame list would its superclass be able to handle, so I don't think the assertion itself really makes much sense.
Flags: needinfo?(xidorn+moz)
(In reply to Xidorn Quan [:xidorn] UTC-8 (less responsive Nov 5 ~ Dec 16) from comment #4) > Frame of any HTML element can get a ::backdrop pseudo-element when it goes > to fullscreen, and kBackdropList is for storing the placeholder of a > BackdropFrame, which is the frame of ::backdrop pseudo-element. I see, thanks for elaborating. > In general, I don't think subclasses should put > assumption on what frame list would its superclass be able to handle, so I > don't think the assertion itself really makes much sense. I disagree with that. Adding new child lists and hoping that frame subclasses just handle them correctly is a recipe for disaster, which is what these assertions are intended to catch. It's the concrete frame class that handles Reflow among other things, and it needs to be aware of all its child frames. It *may delegate* handling some of them to its superclass, but that should be a conscious choice by the subclass. In this case it means that the placeholders on this list are never reflowed, for example. Not a big deal perhaps since nsPlaceholderFrame::Reflow doesn't do much, but technically it's a violation of frame tree invariants. http://searchfox.org/mozilla-central/rev/c99d035f00dd894feff38e4ad28a73fb679c63a6/layout/generic/nsPlaceholderFrame.cpp#119
Assignee: nobody → mats
Severity: normal → minor
OS: Unspecified → All
Priority: -- → P4
Hardware: Unspecified → All
No functional changes -- only touches DEBUG code.
Attachment #8927107 - Flags: review?(dholbert)
Attachment #8927107 - Flags: review?(dholbert) → review+
Pushed by mpalmgren@mozilla.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/dedc4be5ce80 Make nsGridContainerFrame aware of the ::backdrop placeholder list. r=dholbert
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: