nmh-workers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nmh-workers] warning when attaching rfc822 message


From: Ken Hornstein
Subject: Re: [Nmh-workers] warning when attaching rfc822 message
Date: Sun, 13 Apr 2014 19:45:20 -0400

>It looks like nothing had been called to set c_encoding before
>InitMessage() is called.  I suspect that we're seeing this now
>because attach used to use text/plain or application/octet-stream
>in the past, but now it's using message/rfc822.

Okay, so I looked at this.  It looks like the simplest thing to do is
make init_decoded_content() set a default CTE (probably 7bit is appropriate).
The actual CTE is set in scan_content(), so having a default here would
make the various parts the code in mhparse.c happy (an example of how bad
the API is here; various parts of programs call into routines in mhparse.c
with wildly differing expectations).

But as always ... there's a wrinkle.  It looks like we always set a CTE
of 7bit for message/rfc822 parts.  But as I read it, that's not correct
if the message/rfc822 contains 8-bit characters; in that case it should be
8bit (or perhaps binary, but we don't really handle encoding anything in
binary).  Do other people agree with my reading of RFC 2046?  If so,
that change should be simple.

--Ken



reply via email to

[Prev in Thread] Current Thread [Next in Thread]