diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-08-23 02:12:47 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-08-23 02:12:47 +0100 |
commit | a04ed100da7a88bf6a8bf2f1ecb6a77fbb1ed1f8 (patch) | |
tree | 6310dd7d9a0355e99d445af725ececaaea432bce /src/util.h | |
parent | 7d2af49e0f344d78dc68d16f3db318be35430b38 (diff) | |
download | rspamd-a04ed100da7a88bf6a8bf2f1ecb6a77fbb1ed1f8.tar.gz rspamd-a04ed100da7a88bf6a8bf2f1ecb6a77fbb1ed1f8.zip |
Add the tolower variant of strlcpy function.
Diffstat (limited to 'src/util.h')
-rw-r--r-- | src/util.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/util.h b/src/util.h index c95cc5448..405d289a3 100644 --- a/src/util.h +++ b/src/util.h @@ -186,7 +186,7 @@ void g_queue_clear (GQueue *queue); #endif -/* +/** * Copy src to dest limited to len, in compare with standart strlcpy(3) rspamd strlcpy does not * traverse the whole string and it is possible to use it for non NULL terminated strings. This is * more like memccpy(dst, src, size, '\0') @@ -198,6 +198,15 @@ void g_queue_clear (GQueue *queue); */ gsize rspamd_strlcpy (gchar *dst, const gchar *src, gsize siz); +/** + * Lowercase strlcpy variant + * @param dst + * @param src + * @param siz + * @return + */ +gsize rspamd_strlcpy_tolower (gchar *dst, const gchar *src, gsize siz); + /* * Strip <> from email address */ |