mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-27 19:59:17 +00:00
When the user hits <Ctrl-Backspace> where the previous content has the format [Punctuation|Seperator]+ before the cursor, there will be a size_t index underflow in TextDocument::first_word_break_before, which returns an invalid word break position with a huge column index (18446744073709551615, -1 in size_t). The invalid text position later used for executing RemoveTextCommand will cause a crash. The while loop condition in TextDocument::first_word_break_before is not right, the loop will never stop when the target.column() becomes 0 inside.
48 KiB
48 KiB