BASE64: forcefully terminate it after deciphering it.
[citadel] / libcitadel / lib / stringbuf.c
index 5e89ea2..4368646 100644 (file)
@@ -2823,6 +2823,8 @@ int StrBufDecodeBase64(StrBuf *Buf)
        free(Buf->buf);
        Buf->buf = xferbuf;
        Buf->BufUsed = siz;
+
+       Buf->buf[Buf->BufUsed] = '\0';
        return siz;
 }