summaryrefslogtreecommitdiff
path: root/fs/unicode/utf8-norm.c
diff options
context:
space:
mode:
authorGabriel Krisman Bertazi <krisman@collabora.co.uk>2019-04-25 13:51:22 -0400
committerTheodore Ts'o <tytso@mit.edu>2019-04-25 13:51:22 -0400
commit9d53690f0d4e5686e80f034ea584b7a822b356d3 (patch)
treec123dcc3f2e193f584acc2560a1358d546e66810 /fs/unicode/utf8-norm.c
parenta8384c68797ee022f5fd7bcef5f4cc57863d4042 (diff)
unicode: implement higher level API for string handling
This patch integrates the utf8n patches with some higher level API to perform UTF-8 string comparison, normalization and casefolding operations. Implemented is a variation of NFD, and casefold is performed by doing full casefold on top of NFD. These algorithms are based on the core implemented by Olaf Weber from SGI. Signed-off-by: Gabriel Krisman Bertazi <krisman@collabora.co.uk> Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/unicode/utf8-norm.c')
-rw-r--r--fs/unicode/utf8-norm.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/unicode/utf8-norm.c b/fs/unicode/utf8-norm.c
index 848b93e97f50..20d440c3f2db 100644
--- a/fs/unicode/utf8-norm.c
+++ b/fs/unicode/utf8-norm.c
@@ -38,6 +38,12 @@ int utf8version_is_supported(u8 maj, u8 min, u8 rev)
}
EXPORT_SYMBOL(utf8version_is_supported);
+int utf8version_latest(void)
+{
+ return utf8vers;
+}
+EXPORT_SYMBOL(utf8version_latest);
+
/*
* UTF-8 valid ranges.
*