nmh-workers
[Top] [All Lists]

Re: [Nmh-workers] Understanding nmh (aka. What's the goal) [ really non-ASCII message bodies ]

2010-12-07 11:49:11
[2010-12-07 09:10] Jon Steinhart <jon(_at_)fourwinds(_dot_)com>
[2010-12-07 08:27] Jon Steinhart <jon(_at_)fourwinds(_dot_)com>
Sounds good.  Is the patch that you sent out complete?  I don't see an 
option
that enables/disables this behavior and I think that there should be one.

I believe it's correct that there is no switch.

If one wants to deactivate it, do not specify -attach.

If -attach is given, I believe the changes are fixes for broken
behavior. Your attachment system lacks some awareness for non-ASCII
text, which you probably don't deal with much. This is improved with
my patch.

OK.  I think that there should be a switch.  I guess it bugs me to see the
character-by-character examination of the message body on by default.

The char-by-char examination is ugly, yes.


I understand that my attachment system does not handle non-ASCII message
bodies, but again, that's because non-ASCII message bodies are not "legal".
I think that you have justified extending nmh to handle "illegal" message
bodies.  I'm just nitpicking on the implementation details.

With MIMEification, they are legal.

I want nmh to convert illegal draft messages to legal messages.
Currently nmh sends illegal messages if the user composes such ones.
With my patch nmh cares to only send legal messages. Programs should
support humans if possible.


Could you please explain again how you get the character set information
for non-ASCII message bodies?  Sorry that I didn't save your original
message on this.  I seem to recall that you got it from the profile; I
would rather see you get this from the LANG environment variable.

I just leave it up to buildmimeproc to find out. :-) We don't need to
do it at several places. I only say it's text/plain but nothing about
the encoding.

The man page of mhbuild(1) writes:

    If a text content contains any 8-bit characters (characters with the
    high bit set) and the character set is not specified as above,  then
    mhbuild will  assume  the character  set  is  of  the type given by
    the environment variable MM_CHARSET.  If this environment variable is
    not set, then the character set will  be  labeled  as “x-unknown”.

    If  a  text  content  contains  only 7-bit characters and the
    character set is not specified as above, then the character set will
    be labeled as “us-ascii”.

This information probably is outdated, but generally it hits the
point, probably the code is already better (in respect to MM_CHARSET).


BTW, I would suggest using isascii() rather than (*p > 127 || *p < 0).

I just kept what you once wrote. ;-P

But, yes, you are right.


meillo

_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
http://lists.nongnu.org/mailman/listinfo/nmh-workers

<Prev in Thread] Current Thread [Next in Thread>