[wpt-sync] Sync PR 30904 - [layout] Fix metrics DCHECK.
Categories
(Core :: Layout: Block and Inline, task, P4)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox95 | --- | fixed |
People
(Reporter: wpt-sync, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 30904 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/30904
Details from upstream follow.
Ian Kilpatrick <ikilpatrick@chromium.org> wrote:
[layout] Fix metrics DCHECK.
Previously we'd hit this check quite often in clusterfuzz:
Crash Type: CHECK failure
Crash Address:
Crash State:
!metrics_.IsEmpty() || IsEmptyLineBox() in ng_physical_line_box_fragment.cc
blink::NGPhysicalLineBoxFragment::NGPhysicalLineBoxFragment
scoped_refptr\<blink::NGPhysicalLineBoxFragment> base::MakeRefCounted\<blink::NGPhThis particular testcase is an atomic-inline with a saturated -ve margin
at the bottom.As a result the call to BaselineMetrics within the inline layout
algorithm:
https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/layout/ng/inline/ng_inline_layout_algorithm.cc;l=589-593?q=baselinemetrics&ss=chromiumwould result in a FontHeight of [LayoutUnit::Min(), LayoutUnit()].
This would return true for FontHeight::IsEmpty() as it only checked the
ascent.This fixes the issue by checking the descent as will within IsEmpty().
Bug: 1243485
Change-Id: I63d9dd57a6e08dd361f21c68b60fabe025e7befc
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3173984
Commit-Queue: Koji Ishii \<kojii@chromium.org>
Reviewed-by: Koji Ishii \<kojii@chromium.org>
Cr-Commit-Position: refs/heads/main@{#923759}
| Assignee | ||
Updated•4 years ago
|
| Assignee | ||
Comment 1•4 years ago
|
||
| Assignee | ||
Comment 2•4 years ago
|
||
CI Results
Ran 11 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 1 tests
Status Summary
Firefox
PASS: 1
Chrome
PASS: 1
Safari
PASS: 1
Links
Comment 5•4 years ago
|
||
| bugherder | ||
Description
•