From 796f5a869e2330818f549ebec74f4b18e937f1c7 Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Thu, 9 Apr 2020 21:58:10 -0400 Subject: Factor out templateURL --- archive.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'archive.h') diff --git a/archive.h b/archive.h index 6cc7c5f..5a80748 100644 --- a/archive.h +++ b/archive.h @@ -59,7 +59,6 @@ static inline void envelopeFree(struct Envelope envelope) { } #define TEMPLATE(...) #__VA_ARGS__ -#define ESCAPE_URL_CAP(len) (3 * (len)) struct Variable { const char *name; @@ -73,8 +72,9 @@ int escapeXML(FILE *file, const char *str); int templateRender( FILE *file, const char *template, - const struct Variable *vars, EscapeFn *escape + const struct Variable vars[], EscapeFn *escape ); +char *templateURL(const char *template, const struct Variable vars[]); #define MBOX_HEADERS \ "Date Subject From Sender Reply-To To Cc Bcc " \ -- cgit 1.4.1