diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-05-04 15:20:24 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-05-04 15:20:24 +0100 |
commit | 798bd5e86f7941dd87884a4ea15c9a15179ac811 (patch) | |
tree | 94823482c4b436b2e5cc4186b495c2545a4ee7ec /src/libutil/str_util.h | |
parent | 6bb2daddb07642bbd5acb6ae8e5070d7eba49352 (diff) | |
download | rspamd-798bd5e86f7941dd87884a4ea15c9a15179ac811.tar.gz rspamd-798bd5e86f7941dd87884a4ea15c9a15179ac811.zip |
[Feature] Improve levenshtein distance function
- Use g_malloc instead of alloca
- Allow to set variable replacement cost
- Update lua util.levenshtein_distance
Diffstat (limited to 'src/libutil/str_util.h')
-rw-r--r-- | src/libutil/str_util.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libutil/str_util.h b/src/libutil/str_util.h index 68f84f7bc..a63b160dd 100644 --- a/src/libutil/str_util.h +++ b/src/libutil/str_util.h @@ -217,7 +217,7 @@ gsize rspamd_decode_url (gchar *dst, const gchar *src, gsize size); * @return */ gint rspamd_strings_levenshtein_distance (const gchar *s1, gsize s1len, - const gchar *s2, gsize s2len); + const gchar *s2, gsize s2len, guint replace_cost); /** * Fold header using rfc822 rules, return new GString from the previous one |