Subject: Re: OT: Carriage return inserts in MS Exchange email -- fix?
From: "A. Pagaltzis" <>
Date: Fri, 22 Jul 2005 03:50:44 +0200

* A. Pagaltzis <> [2005-07-22 01:45]:
> Add “;format=flowed” to the Content-Type and watch the CRs
> disappear from view. At least in mutt. I’m not sure this is the
> right fix, to be honest; but it’s the only thing which managed to
> excise those pesky CRs. (See <>
> as well as RFC2646.)

Here’s a generic procmail recipe:

    * ^Content-Transfer-Encoding:.*quoted-printable
    * ^Content-Type:.*text/plain
    * ! ^Content-Type:.*format=flowed
    * B ?? \r
        CONTENT_TYPE=`formail -x Content-Type`

        :0 fhw
        | formail -i "Content-Type:$CONTENT_TYPE; format=flowed"

This checks quoted-printable encoded text/plain messages that
don’t use format=flowed for CRs in the message body. (procmail
decodes the transfer encoding before applying regexen, hence `\r`
instead `=0D`.)

I’m still unsure whether this is the correct thing to do, but the
only other solution I found is to sed the CRs out of the body,
which is way more invasive.

Aristotle Pagaltzis // <>