You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
forgejo/modules/charset
zeripath bc4764ffc6
Detect truncated utf-8 characters at the end of content as still representing utf-8 (#19773)
Our character detection algorithm can potentially incorrectly detect utf-8 as iso-8859-x
if there is a truncated character at the end of the partially read file.

This PR changes the detection algorithm to truncated utf8 characters at the end of the
buffer.

Fix #19743

Signed-off-by: Andrew Thornton <art27@cantab.net>
2 years ago
..
charset.go Detect truncated utf-8 characters at the end of content as still representing utf-8 (#19773) 2 years ago
charset_test.go Detect truncated utf-8 characters at the end of content as still representing utf-8 (#19773) 2 years ago
escape.go Don't treat BOM escape sequence as hidden character. (#18909) 2 years ago
escape_test.go Don't treat BOM escape sequence as hidden character. (#18909) 2 years ago