From d40b93f83005fb433bd14870c66e0fa47b82b025 Mon Sep 17 00:00:00 2001 From: Wilfried Goesgens Date: Sat, 7 Dec 2013 17:26:38 +0100 Subject: [PATCH] STRBUF: RFC2047-Encode Message - \r == 10 --- libcitadel/lib/stringbuf.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/libcitadel/lib/stringbuf.c b/libcitadel/lib/stringbuf.c index dd15b0801..9275c26b7 100644 --- a/libcitadel/lib/stringbuf.c +++ b/libcitadel/lib/stringbuf.c @@ -2977,7 +2977,6 @@ int StrBufRFC2047encode(StrBuf **target, const StrBuf *source) ch = (unsigned char) source->buf[i]; if ((ch < 32) || (ch > 126) || - (ch == 61) || (ch == '=') || (ch == '?') || (ch == '_') || @@ -3037,12 +3036,12 @@ StrBuf *StrBufRFC2047encodeMessage(const StrBuf *EncodeMe) Optr = OutBuf->buf + Offset; OEptr = OutBuf->buf + OutBuf->BufSize; } - if ((*ptr == '\r') || (*ptr == '\n')) + if (*ptr == '\r') { /* ignore carriage returns */ ptr ++; } - else if (*ptr == 10) { + else if (*ptr == '\n') { /* hard line break */ if ((LinePos > 0) && (isspace(*(Optr-1)))) { -- 2.30.2