aboutsummaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorMartin Schanzenbach <schanzen@gnunet.org>2022-01-18 11:05:41 +0100
committerMartin Schanzenbach <schanzen@gnunet.org>2022-01-18 11:05:41 +0100
commit54554ca531d018b965cc04fe5046e7df68eb27f9 (patch)
treec2c2128b3465f80d355a0d97d9c5ac30e5b01c91 /src/include
parent56b8101fe913c113fdb9fa2f9149861752bbea12 (diff)
downloadgnunet-54554ca531d018b965cc04fe5046e7df68eb27f9.tar.gz
gnunet-54554ca531d018b965cc04fe5046e7df68eb27f9.zip
GNS: Towards NFC
Diffstat (limited to 'src/include')
-rw-r--r--src/include/gnunet_gnsrecord_lib.h9
-rw-r--r--src/include/gnunet_strings_lib.h12
2 files changed, 21 insertions, 0 deletions
diff --git a/src/include/gnunet_gnsrecord_lib.h b/src/include/gnunet_gnsrecord_lib.h
index f00a5d0f8..94e20323d 100644
--- a/src/include/gnunet_gnsrecord_lib.h
+++ b/src/include/gnunet_gnsrecord_lib.h
@@ -418,6 +418,15 @@ GNUNET_GNSRECORD_is_expired (const struct GNUNET_GNSRECORD_Data *rd);
418 418
419 419
420/** 420/**
421 * Normalize a UTF-8 string to UTF-8 NFC
422 * @param src source string
423 * @return converted result
424 */
425char *
426GNUNET_GNSRECORD_string_normalize (const char *src);
427
428
429/**
421 * Convert a UTF-8 string to UTF-8 lowercase 430 * Convert a UTF-8 string to UTF-8 lowercase
422 * @param src source string 431 * @param src source string
423 * @return converted result 432 * @return converted result
diff --git a/src/include/gnunet_strings_lib.h b/src/include/gnunet_strings_lib.h
index ef9d5ac58..9dd2f733e 100644
--- a/src/include/gnunet_strings_lib.h
+++ b/src/include/gnunet_strings_lib.h
@@ -158,6 +158,18 @@ GNUNET_STRINGS_to_utf8 (const char *input,
158 158
159 159
160/** 160/**
161 * Normalize the utf-8 input string to NFC.
162 * Output needs to be allocated appropriately.
163 *
164 * @param input input string
165 * @param output output buffer
166 */
167void
168GNUNET_STRINGS_utf8_normalize (const char *input,
169 char *output);
170
171
172/**
161 * Convert the len bytes-long UTF-8 string 173 * Convert the len bytes-long UTF-8 string
162 * given in input to the given charset. 174 * given in input to the given charset.
163 * 175 *