diff options
Diffstat (limited to 'src/printf.h')
-rw-r--r-- | src/printf.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/printf.h b/src/printf.h index 74f665a2d..0d41bdc80 100644 --- a/src/printf.h +++ b/src/printf.h @@ -55,7 +55,17 @@ */ gint rspamd_sprintf (gchar *buf, const gchar *fmt, ...); gint rspamd_fprintf (FILE *f, const gchar *fmt, ...); -gint rspamd_snprintf (gchar *buf, size_t max, const gchar *fmt, ...); -gchar *rspamd_vsnprintf (gchar *buf, size_t max, const gchar *fmt, va_list args); +gint rspamd_snprintf (gchar *buf, glong max, const gchar *fmt, ...); +gchar *rspamd_vsnprintf (gchar *buf, glong max, const gchar *fmt, va_list args); + +/* + * Escape rspamd string to write it to log file or other 7 bit prefferable places + * + * @param dst destination string + * @param src source string + * @param len length of destination buffer + * @return pointer to end of buffer + */ +gchar * rspamd_escape_string (gchar *dst, const gchar *src, glong len); #endif /* PRINTF_H_ */ |