aboutsummaryrefslogtreecommitdiffstats
path: root/src/libutil/fstring.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2020-02-10 11:17:21 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2020-02-10 11:46:43 +0000
commitf8d2466d3a36e8418f2d306ebaaed0ef962737b0 (patch)
tree9787f302af8d168bd5c587bd4e76c7a7d6c54856 /src/libutil/fstring.c
parent9091c3739b5f99a0a29e5c7a64fc93bef83955d6 (diff)
downloadrspamd-f8d2466d3a36e8418f2d306ebaaed0ef962737b0.tar.gz
rspamd-f8d2466d3a36e8418f2d306ebaaed0ef962737b0.zip
[Minor] Eliminate g_utf8_validate
Diffstat (limited to 'src/libutil/fstring.c')
-rw-r--r--src/libutil/fstring.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libutil/fstring.c b/src/libutil/fstring.c
index b00b71e12..652d72d14 100644
--- a/src/libutil/fstring.c
+++ b/src/libutil/fstring.c
@@ -15,6 +15,7 @@
*/
#include "fstring.h"
#include "str_util.h"
+#include "contrib/fastutf8/fastutf8.h"
#ifdef WITH_JEMALLOC
@@ -274,7 +275,7 @@ rspamd_fstrhash_lc (const rspamd_ftok_t * str, gboolean is_utf)
if (is_utf) {
while (end < str->begin + str->len) {
- if (!g_utf8_validate (p, str->len, &end)) {
+ if (rspamd_fast_utf8_validate (p, str->len) != 0) {
return rspamd_fstrhash_lc (str, FALSE);
}
while (p < end) {