haikuwebkit/LayoutTests/fast/replaced
Zalan Bujtas dc56a5b640 [AspectRatio] Out-of-flow box with intrinsic width (e.g. <img>) may trigger infinite recursion
https://bugs.webkit.org/show_bug.cgi?id=224113

Reviewed by Rob Buis.

Source/WebCore:

This covers the case when the out-of-flow box has intrinsic width (replaced box) and
the max-width is also set to "intrinsic" meaning content size dependent. In such cases
the aspect ratio computation ends up recursing around RenderBox::computeReplacedLogicalWidthRespectingMinMaxWidth.
This path checks if the out-of-flow box's horizontal size is also constrained by the intrinsic width.

Test: fast/replaced/infinite-recursion-with-intrinsic-width.html

* rendering/RenderBox.cpp:
(WebCore::shouldComputeLogicalWidthFromAspectRatioAndInsets):

LayoutTests:

* fast/replaced/infinite-recursion-with-intrinsic-width-expected.txt: Added.
* fast/replaced/infinite-recursion-with-intrinsic-width.html: Added.


Canonical link: https://commits.webkit.org/236093@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@275430 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2021-04-02 19:30:12 +00:00
..
resources
vertical-lr
vertical-rl
001.html
002.html
003.html
004.html
005.html
006.html
007.html
008-expected.txt
008.html
absolute-image-sizing.html
absolute-position-percentage-height.html
absolute-position-percentage-width.html
absolute-position-with-auto-height-and-top-and-bottom.html
absolute-position-with-auto-width-and-left-and-right.html
applet-disabled-positioned.html
applet-display-none.html
applet-rendering-java-disabled.html
before-content-intrinsic-crash-expected.txt Do not attempt to compute min/max width. 2016-05-05 22:16:43 +00:00
before-content-intrinsic-crash.html
border-radius-clip-content-edge-expected.png
border-radius-clip-content-edge-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
border-radius-clip-content-edge.html Remove remaining alternative preference setting mechanisms from LayoutTests 2020-11-01 20:09:38 +00:00
border-radius-clip-expected.png
border-radius-clip.html
computed-image-width-with-percent-height-and-fixed-ancestor-expected.txt
computed-image-width-with-percent-height-and-fixed-ancestor-vertical-lr-expected.txt
computed-image-width-with-percent-height-and-fixed-ancestor-vertical-lr.html
computed-image-width-with-percent-height-and-fixed-ancestor.html
computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor-vertical-lr-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor-vertical-lr.html
computed-image-width-with-percent-height-inside-table-cell-and-fixed-ancestor.html
container-width-zero-expected.txt
container-width-zero.html
css-content-and-webkit-mask-box-image-crash-expected.txt
css-content-and-webkit-mask-box-image-crash.html
embed-display-none.html
encrypted-pdf-as-object-and-embed-expected.txt
encrypted-pdf-as-object-and-embed.html
frame-removed-during-resize-expected.txt
frame-removed-during-resize-smaller-expected.txt
frame-removed-during-resize-smaller.html
frame-removed-during-resize.html
iframe-with-percentage-height-within-table-with-anonymous-table-cell-expected.txt
iframe-with-percentage-height-within-table-with-anonymous-table-cell.html
iframe-with-percentage-height-within-table-with-table-cell-ignore-height-expected.txt
iframe-with-percentage-height-within-table-with-table-cell-ignore-height.html
image-map-2-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
image-map-2.html
image-map-bug16782-expected.txt
image-map-bug16782.html
image-map-expected.txt
image-map.html
image-onload.html
image-resize-width.html
image-sizing.html
image-solid-color-with-alpha.html
image-tag-expected.txt
image-tag.html
infinite-recursion-with-intrinsic-width-expected.txt [AspectRatio] Out-of-flow box with intrinsic width (e.g. <img>) may trigger infinite recursion 2021-04-02 19:30:12 +00:00
infinite-recursion-with-intrinsic-width.html [AspectRatio] Out-of-flow box with intrinsic width (e.g. <img>) may trigger infinite recursion 2021-04-02 19:30:12 +00:00
inline-box-wrapper-handover.html
invalid-object-with-fallback-expected.txt
invalid-object-with-fallback.html
max-height-percent-inside-auto-block-expected.html
max-height-percent-inside-auto-block.html
max-width-percent.html
maxheight-percent.html
maxheight-pxs.html
maxwidth-percent.html
maxwidth-pxs.html
minheight-percent.html
minheight-pxs.html
minwidth-percent.html
minwidth-pxs.html
no-focus-ring-embed-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
no-focus-ring-embed.html
no-focus-ring-iframe-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
no-focus-ring-iframe.html
no-focus-ring-object-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
no-focus-ring-object.html
object-align-hspace-vspace.html
object-display-none.html
object-param-no-name-expected.txt
object-param-no-name.html
object-with-non-empty-classid-triggers-fallback-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
object-with-non-empty-classid-triggers-fallback.html
outline-replaced-elements-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
outline-replaced-elements-offset-expected.html
outline-replaced-elements-offset.html
outline-replaced-elements.html Remove remaining alternative preference setting mechanisms from LayoutTests 2020-11-01 20:09:38 +00:00
pdf-as-embed-with-no-mime-type-is-not-blank-expected-mismatch.html REGRESSION: Safari unable to load PDF in <embed> (docs.legalconnect.com) 2020-10-08 00:01:27 +00:00
pdf-as-embed-with-no-mime-type-is-not-blank.html Remove remaining alternative preference setting mechanisms from LayoutTests 2020-11-01 20:09:38 +00:00
pdf-as-image.html
pdf-as-object-and-embed-expected.html
pdf-as-object-and-embed.html
percent-height-in-anonymous-block-expected.txt
percent-height-in-anonymous-block-in-table.html
percent-height-in-anonymous-block-widget.html embed element without src and type attributes should represent nothing 2015-11-07 23:48:08 +00:00
percent-height-in-anonymous-block.html
preferred-widths-expected.txt Remove trailing spaces from expected.txt files (excluding WPT for now since that contains too many) 2020-09-27 02:15:19 +00:00
preferred-widths.html
render-inline-cast-to-render-box-crash-expected.txt
render-inline-cast-to-render-box-crash.html Bad cast in RenderBox::computeReplacedLogicalHeightUsing 2012-08-14 00:11:35 +00:00
replaced-breaking-mixture.html
replaced-breaking.html
replaced-child-of-absolute-with-auto-height.html
replaced-element-with-percentage-width-inside-flow-asserts-expected.txt
replaced-element-with-percentage-width-inside-flow-asserts.html
replaced-last-line-layout-expected.html
replaced-last-line-layout.html
selection-rect-expected.txt
selection-rect-in-table-cell.html
selection-rect-transform.html
selection-rect.html
table-percent-height-positioned-expected.png
table-percent-height-positioned-expected.txt
table-percent-height-positioned.html
table-percent-height-text-controls-expected.txt
table-percent-height-text-controls.html
table-percent-height.html
table-percent-width-expected.txt
table-percent-width.html
table-replaced-element-expected.txt
table-replaced-element.html
three-selects-break-expected.png
three-selects-break.html
ul-li-word-break-break-word-expected.html
ul-li-word-break-break-word.html
vertical-resize-100percent-element-expected.txt
vertical-resize-100percent-element.html
vertical-writing-mode-max-logical-width-replaced-expected.txt
vertical-writing-mode-max-logical-width-replaced.html
width100percent-button.html
width100percent-checkbox.html
width100percent-image.html
width100percent-menulist.html
width100percent-radio.html
width100percent-searchfield.html
width100percent-textarea.html
width100percent-textfield.html
zero-width-image-force-linebreak-expected.html
zero-width-image-force-linebreak.html