Closed
Bug 1140198
Opened 9 years ago
Closed 9 years ago
Crash [@ nsCSSFrameConstructor::WipeContainingBlock] with display:contents
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
FIXED
mozilla39
Tracking | Status | |
---|---|---|
firefox39 | --- | fixed |
People
(Reporter: jruderman, Assigned: MatsPalmgren_bugz)
References
Details
(Keywords: assertion, crash, testcase)
Crash Data
Attachments
(3 files)
###!!! ASSERTION: Must have non-inline, non-ib-split, non-pseudo frame as root (or child of root, for a table root)!: 'aContainingBlock', file layout/base/nsCSSFrameConstructor.cpp, line 12120 Followed by a crash [@ nsCSSFrameConstructor::WipeContainingBlock]
Reporter | ||
Comment 1•9 years ago
|
||
Assignee | ||
Updated•9 years ago
|
Assignee: nobody → mats
OS: Mac OS X → All
Hardware: x86_64 → All
Assignee | ||
Comment 2•9 years ago
|
||
We currently enforce a block frame for the root, but we didn't fixup the 'display' style. The CSS spec says we should do that, which is nice because it also fixes the crash. :-) The problem was that we never found a block ancestor in this loop: http://hg.mozilla.org/mozilla-central/annotate/7d85ac833cff/layout/base/nsCSSFrameConstructor.cpp#l12119 because "IsInlineOutside()" is true for display:contents. https://treeherder.mozilla.org/#/jobs?repo=try&revision=5a0d2c2ffbdb
Attachment #8574207 -
Flags: review?(roc)
Attachment #8574207 -
Flags: review?(roc) → review+
Assignee | ||
Comment 3•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/27ac269bb796
Status: NEW → RESOLVED
Closed: 9 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Assignee | ||
Comment 4•9 years ago
|
||
Sorry, wrong link above - here's the correct link: https://hg.mozilla.org/integration/mozilla-inbound/rev/aa19896bead7
Comment 5•9 years ago
|
||
There's a test, layout/style/test/test_root_node_display.html (in mochitest-5 on desktop), which tests that the result of this is not true, "root node should make 'display:contents' compute to the same value that it computes to on a floated element - got block, expected contents", now permafailing.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 6•9 years ago
|
||
My bad. I'll land a small tweak to that test for now to make it green again.
Assignee | ||
Comment 7•9 years ago
|
||
Fixed the failing test: https://hg.mozilla.org/integration/mozilla-inbound/rev/99a276974d6d
Assignee | ||
Comment 8•9 years ago
|
||
David, can you confirm I'm reading the spec correctly here? http://dev.w3.org/csswg/css-display/#transformations (last paragraph) "The root element’s display type is always blockified. Additionally, a display-outside of contents computes to block-level on the root element." That's what my patch here tries to implement. The spec also says (first paragraph), "Some layout effects require blockification or inlinification of the box type, causing the box’s display-outside property, if it is not none or contents, to compute to block-level or inline-level (respectively)." which is why I intentionally didn't do this inside EnsureBlockDisplay, since the spec explicitly excludes 'contents' there.
Flags: needinfo?(dbaron)
Yes, that seems right. display:contents overrides those other things, but it's not allowed to override there being only one root.
Flags: needinfo?(dbaron)
Comment 10•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/27ac269bb796 https://hg.mozilla.org/mozilla-central/rev/aa19896bead7 https://hg.mozilla.org/mozilla-central/rev/99a276974d6d
Status: REOPENED → RESOLVED
Closed: 9 years ago → 9 years ago
status-firefox39:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
You need to log in
before you can comment on or make changes to this bug.
Description
•