From daeff6f5f8a6757760110242db30b359a8526136 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Wilfried=20G=C3=B6esgens?= Date: Sun, 25 Jul 2010 15:40:12 +0000 Subject: [PATCH] * StrBufDecodeBase64(): init output buffer so in case of an empty / illegal base64 string its defined. --- libcitadel/lib/stringbuf.c | 1 + 1 file changed, 1 insertion(+) diff --git a/libcitadel/lib/stringbuf.c b/libcitadel/lib/stringbuf.c index 250b3109c..fa51fcce7 100644 --- a/libcitadel/lib/stringbuf.c +++ b/libcitadel/lib/stringbuf.c @@ -2259,6 +2259,7 @@ int StrBufDecodeBase64(StrBuf *Buf) if (Buf == NULL) return -1; xferbuf = (char*) malloc(Buf->BufSize); + *xferbuf = '\0'; siz = CtdlDecodeBase64(xferbuf, Buf->buf, Buf->BufUsed); -- 2.30.2