Skip to content

test(display): cover malformed UTF-8 and fix boundary read - #596

Merged
gg582 merged 1 commit into
uncensoredfrom
test/crash-regressions
Nov 2, 2026
Merged

gg582 merged 1 commit into
uncensoredfrom
test/crash-regressions

Conversation

@gg582

@gg582 gg582 commented Nov 2, 2026

Copy link
Copy Markdown
Member

Summary

  • add exact-allocation regression coverage for truncated multi-byte UTF-8 input
  • add invalid continuation-byte coverage
  • validate UTF-8 continuation bytes before decoding codepoints

Crash fixed

The new truncated-input test reproduced an AddressSanitizer heap-buffer-overflow in display_model_wrap_line: a two-byte buffer containing a four-byte UTF-8 lead and NUL was read past its terminator. The display tests now pass under ASan/UBSan.

Verification

  • make -j2
  • make unit-test
  • make SANITIZE=address,undefined unit-test

@gg582
gg582 merged commit 3683006 into uncensored Nov 2, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant