From: Wilfried Goesgens Date: Tue, 7 Dec 2010 21:24:49 +0000 (+0100) Subject: Be more conservative about when not to apply binary searching for the next boundary... X-Git-Tag: v8.01~252^2~280 X-Git-Url: https://code.citadel.org/?a=commitdiff_plain;h=a2ccca3758d5352be9ebdaa78960ab2852b911d6;p=citadel.git Be more conservative about when not to apply binary searching for the next boundary or not. --- diff --git a/libcitadel/lib/mime_parser.c b/libcitadel/lib/mime_parser.c index e3d04bb01..3b10588b7 100644 --- a/libcitadel/lib/mime_parser.c +++ b/libcitadel/lib/mime_parser.c @@ -472,11 +472,15 @@ static long parse_MimeHeaders(interesting_mime_headers *m, static int IsAsciiEncoding(interesting_mime_headers *m) { + if ((m->b[encoding].len != 0) && - (strcmp(m->b[encoding].Key, "binary") == 0)) - return 0; - else + (strcasecmp(m->b[encoding].Key, "base64") == 0)) + return 1; + if ((m->b[encoding].len != 0) && + (strcmp(m->b[encoding].Key, "quoted-printable") == 0)) return 1; + + return 0; } static char *FindNextContent(char *ptr,