summaryrefslogtreecommitdiffstats
path: root/sendlib.c
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>1999-06-14 21:20:42 +0000
committerThomas Roessler <roessler@does-not-exist.org>1999-06-14 21:20:42 +0000
commitedfda8e884b92c31e0fe1c9a27cc32077862059f (patch)
tree945e4bd899f49ceb2c2e01405f84542d2a0f2355 /sendlib.c
parent35ac12bba5c3065afc25474dd21588da70ea42de (diff)
- Handle CRLF properly in non-text MIME parts.
- Correctly parse attachments with CRLF line endings, but without a trailing CRLF.
Diffstat (limited to 'sendlib.c')
-rw-r--r--sendlib.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sendlib.c b/sendlib.c
index cd0b5051..fa4ffce4 100644
--- a/sendlib.c
+++ b/sendlib.c
@@ -539,6 +539,7 @@ static CONTENT *mutt_get_content_info (const char *fname, BODY *b)
}
else if (ch == '\r')
{
+ info->cr = 1;
if ((ch = fgetc (fp)) == EOF)
{
info->binary = 1;
@@ -864,7 +865,7 @@ static void mutt_set_encoding (BODY *b, CONTENT *info)
b->encoding = ENC7BIT;
}
else if (info->lobin || info->hibin || info->binary || info->linemax > 990
- || (option (OPTENCODEFROM) && info->from))
+ || info->cr || (option (OPTENCODEFROM) && info->from))
{
/* Determine which encoding is smaller */
if (1.33 * (float)(info->lobin+info->hibin+info->ascii) < 3.0 * (float) (info->lobin + info->hibin) + (float)info->ascii)