aboutsummaryrefslogtreecommitdiffstats
path: root/src/libutil/fstring.h
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2016-05-09 15:45:43 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2016-05-09 15:45:43 +0100
commit4ef507e1592efbe33ca948f6bc76e4f100921184 (patch)
tree854ebe02911ddc48a76d54624c7b892ba3ccb2c9 /src/libutil/fstring.h
parent6a48a0a416a64c30c8ab89b9f468b523f46b1bb9 (diff)
downloadrspamd-4ef507e1592efbe33ca948f6bc76e4f100921184.tar.gz
rspamd-4ef507e1592efbe33ca948f6bc76e4f100921184.zip
[Feature] Add utility method to convert ftok to C string
Diffstat (limited to 'src/libutil/fstring.h')
-rw-r--r--src/libutil/fstring.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/libutil/fstring.h b/src/libutil/fstring.h
index 127557e40..10916d876 100644
--- a/src/libutil/fstring.h
+++ b/src/libutil/fstring.h
@@ -153,4 +153,12 @@ rspamd_ftok_t *rspamd_ftok_map (const rspamd_fstring_t *s);
rspamd_fstring_t * rspamd_fstring_grow (rspamd_fstring_t *str,
gsize needed_len) G_GNUC_WARN_UNUSED_RESULT;
+/**
+ * Copies ftok to zero terminated string (must be freed using g_free)
+ * @param src
+ * @return
+ */
+gchar *rspamd_ftokdup (const rspamd_ftok_t *src) G_GNUC_WARN_UNUSED_RESULT;
+
+
#endif