projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b52b33e
)
* Repaired the code that decides whether it should not bother converting character...
author
Art Cancro
<ajc@citadel.org>
Tue, 30 Jun 2009 23:53:24 +0000
(23:53 +0000)
committer
Art Cancro
<ajc@citadel.org>
Tue, 30 Jun 2009 23:53:24 +0000
(23:53 +0000)
webcit/msg_renderers.c
patch
|
blob
|
history
diff --git
a/webcit/msg_renderers.c
b/webcit/msg_renderers.c
index d8630588fdde7762a8ac0a046cb60886ac1aeb3b..5b3a6588674157e06ed44d886f7bc5b4d14da408 100644
(file)
--- a/
webcit/msg_renderers.c
+++ b/
webcit/msg_renderers.c
@@
-837,11
+837,6
@@
void render_MAIL_text_plain(wc_mime_attachment *Mime, StrBuf *RawData, StrBuf *F
MimeLoadData(Mime);
}
MimeLoadData(Mime);
}
- /* Boring old 80-column fixed format text gets handled this way... */
- if ((strcasecmp(ChrPtr(Mime->Charset), "us-ascii") == 0) &&
- (strcasecmp(ChrPtr(Mime->Charset), "UTF-8") == 0))
- ConvertIt = 0;
-
#ifdef HAVE_ICONV
if (ConvertIt) {
if (StrLength(Mime->Charset) != 0)
#ifdef HAVE_ICONV
if (ConvertIt) {
if (StrLength(Mime->Charset) != 0)
@@
-853,6
+848,12
@@
void render_MAIL_text_plain(wc_mime_attachment *Mime, StrBuf *RawData, StrBuf *F
if (cs == NULL) {
ConvertIt = 0;
}
if (cs == NULL) {
ConvertIt = 0;
}
+ else if (!strcasecmp(ChrPtr(cs), "utf-8")) {
+ ConvertIt = 0;
+ }
+ else if (!strcasecmp(ChrPtr(cs), "us-ascii")) {
+ ConvertIt = 0;
+ }
else {
ctdl_iconv_open("UTF-8", ChrPtr(cs), &ic);
if (ic == (iconv_t)(-1) ) {
else {
ctdl_iconv_open("UTF-8", ChrPtr(cs), &ic);
if (ic == (iconv_t)(-1) ) {
@@
-897,7
+898,7
@@
void render_MAIL_text_plain(wc_mime_attachment *Mime, StrBuf *RawData, StrBuf *F
for (i = bq; i < bn; i++)
StrBufAppendBufPlain(Target, HKEY("</blockquote>"), 0);
for (i = bq; i < bn; i++)
StrBufAppendBufPlain(Target, HKEY("</blockquote>"), 0);
- if (ConvertIt
== 1
) {
+ if (ConvertIt) {
StrBufConvert(Line, Line1, &ic);
}
StrBufConvert(Line, Line1, &ic);
}