projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5313859
)
fix QP encoding
author
Wilfried Goesgens
<dothebart@citadel.org>
Thu, 18 Aug 2011 09:14:48 +0000
(09:14 +0000)
committer
Wilfried Goesgens
<dothebart@citadel.org>
Thu, 18 Aug 2011 10:45:42 +0000
(10:45 +0000)
- once we decided to QP encode we also need to encode =[]
libcitadel/lib/stringbuf.c
patch
|
blob
|
history
diff --git
a/libcitadel/lib/stringbuf.c
b/libcitadel/lib/stringbuf.c
index 7a841df8f255fcdbfd5c20348639aa2387348a18..114b453e4487849e4a19ee7be996c41a9d4975f5 100644
(file)
--- a/
libcitadel/lib/stringbuf.c
+++ b/
libcitadel/lib/stringbuf.c
@@
-2434,7
+2434,12
@@
int StrBufRFC2047encode(StrBuf **target, const StrBuf *source)
if ((*target)->BufUsed + 4 >= (*target)->BufSize)
IncreaseBuf(*target, 1, 0);
ch = (unsigned char) source->buf[i];
- if ((ch < 32) || (ch > 126) || (ch == 61)) {
+ if ((ch < 32) ||
+ (ch > 126) ||
+ (ch == 61) ||
+ (ch == '[') ||
+ (ch == ']') )
+ {
sprintf(&(*target)->buf[(*target)->BufUsed], "=%02X", ch);
(*target)->BufUsed += 3;
}