Skip to content

Fix UTF-8 buffer prepending in read_stdin#520

Merged
lhecker merged 1 commit into
microsoft:mainfrom
manitofigh:fix-utf8-buf-prepend
Jun 25, 2025
Merged

Fix UTF-8 buffer prepending in read_stdin#520
lhecker merged 1 commit into
microsoft:mainfrom
manitofigh:fix-utf8-buf-prepend

Conversation

@manitofigh

Copy link
Copy Markdown
Contributor

The code zeroed STATE.utf8_len before using it as
a slice index, which causes leftover UTF-8 bytes from
previous reads to be discarded instead of prepended to the buffer

@lhecker lhecker left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ARGH! Thank you for noticing this!

@lhecker lhecker merged commit 7ece8c5 into microsoft:main Jun 25, 2025
3 checks passed
@manitofigh

Copy link
Copy Markdown
Contributor Author

Of course! Thank you for the quick resolution!

Lou32Verbose pushed a commit to Lou32Verbose/edit that referenced this pull request Jan 11, 2026
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.

2 participants