[Webkit-unassigned] [Bug 225593] Remove unnecessary comparison and casting in GlyphBuffer.h

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon May 10 09:05:05 PDT 2021


https://bugs.webkit.org/show_bug.cgi?id=225593

Sam Weinig <sam at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sam at webkit.org
 Attachment #428166|review?                     |review-
              Flags|                            |

--- Comment #3 from Sam Weinig <sam at webkit.org> ---
Comment on attachment 428166
  --> https://bugs.webkit.org/attachment.cgi?id=428166
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=428166&action=review

> Source/WebCore/platform/graphics/GlyphBuffer.h:81
> -        if (result < 0 || static_cast<unsigned>(result) >= stringLength)
> +        if (result >= stringLength)

This is not true on all platforms. When USE(CG) is true, GlyphBufferStringOffset (the type of result) is CFIndex which is 'signed long'.

The real issue that we should try to solve is using the same types here if we can.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20210510/02c2c365/attachment-0001.htm>


More information about the webkit-unassigned mailing list