Changeset 292054 in webkit


Ignore:
Timestamp:
Mar 29, 2022 12:10:01 PM (2 years ago)
Author:
Alan Bujtas
Message:

WebCore::LegacyRootInlineBox::lineSnapAdjustment should bail out on grid line height < 1
https://bugs.webkit.org/show_bug.cgi?id=238465
<rdar://80630664>

Reviewed by Antti Koivisto.

The !gridLineHeight check was added to avoid division by zero but the integral roundToInt() may also produce a 0 value for
gridLineHeight.

  • rendering/LegacyRootInlineBox.cpp:

(WebCore::LegacyRootInlineBox::lineSnapAdjustment const):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r292049 r292054  
     12022-03-29  Alan Bujtas  <zalan@apple.com>
     2
     3        WebCore::LegacyRootInlineBox::lineSnapAdjustment should bail out on grid line height < 1
     4        https://bugs.webkit.org/show_bug.cgi?id=238465
     5        <rdar://80630664>
     6
     7        Reviewed by Antti Koivisto.
     8
     9        The !gridLineHeight check was added to avoid division by zero but the integral roundToInt() may also produce a 0 value for
     10        gridLineHeight.
     11
     12        * rendering/LegacyRootInlineBox.cpp:
     13        (WebCore::LegacyRootInlineBox::lineSnapAdjustment const):
     14
    1152022-03-29  Eric Carlson  <eric.carlson@apple.com>
    216
  • trunk/Source/WebCore/rendering/LegacyRootInlineBox.cpp

    r291946 r292054  
    361361    // the grid should honor line-box-contain.
    362362    LayoutUnit gridLineHeight = lineGridBox->lineBoxBottom() - lineGridBox->lineBoxTop();
    363     if (!gridLineHeight)
     363    if (!roundToInt(gridLineHeight))
    364364        return 0;
    365365
Note: See TracChangeset for help on using the changeset viewer.