[PATCH v2 0/2] commit: improve UTF-8 validation
- From
brian m. carlson <sandals@crustytoothpaste.net>
- Date
- Jul 4, 2013, 17:17 UTC
- Message-ID
- <cover.1372957719.git.sandals@crustytoothpaste.net>
This series contains a pair of patches that improve the validation of the UTF-8 used in commit messages. Invalid codepoints, such as surrogates and guaranteed non-characters, are rejected, along with overlong UTF-8 sequences.
Changes from v1:
* Improved comments to aid those less familiar with Unicode. * Generated test files using printf as part of the test. * Removed FIXME comments for things that have been fixed. * Use a shorter form for detecting surrogate pairs.
brian m. carlson (2): commit: reject invalid UTF-8 codepoints commit: reject overlong UTF-8 sequences
commit.c | 34 ++++++++++++++++++++++++++++------ t/t3900-i18n-commit.sh | 23 +++++++++++++++++++++++ 2 files changed, 51 insertions(+), 6 deletions(-)
-- 1.8.3.1