[Webkit-unassigned] [Bug 232053] Negative length returned by TextUtil::midWordBreak with surrogate pair

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Oct 28 09:58:07 PDT 2021


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

--- Comment #10 from zalan <zalan at apple.com> ---
Comment on attachment 442621
  --> https://bugs.webkit.org/attachment.cgi?id=442621
Patch

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

> Source/WebCore/layout/formattingContexts/inline/text/TextUtil.cpp:178
> +            if (right < startPosition)
> +                right = surrogatePairAwareIndex(middle);

Shouldn't we just simply bail out at this point? We know that our middle point (which becomes the right) falls before the start position. We surely not going to find a non-empty fitting content anymore in here.

-- 
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/20211028/13233934/attachment.htm>


More information about the webkit-unassigned mailing list