Thomas Wolff | 4 Apr 2007 15:57

mime part not displayed

Hi, I repeatedly get mails which do not get displayed by nail.
One (with my name removed) is attached here.

While I am not sure if the mail format is strictly correct - 
it looks a little bit strange with a multipart/alternative 
nested inside a multipart/related - I think nail should still 
be able to recognize and display the contents.

This is with nail 11.4. I wanted to check with the current 12.2 
but unfortunately it did not compile with the following message:
sendout.o: In function `start_mta':
sendout.c:(.text+0x144d): undefined reference to `smtp_auth_var'

Thomas

Attachment (x): application/octet-stream, 15 KiB
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
nail-devel mailing list
nail-devel@...
https://lists.sourceforge.net/lists/listinfo/nail-devel
Gunnar Ritter | 4 Apr 2007 16:21
Picon
Favicon

Re: mime part not displayed

Thomas Wolff <towo@...> wrote:

> Hi, I repeatedly get mails which do not get displayed by nail.
> One (with my name removed) is attached here.
>
> While I am not sure if the mail format is strictly correct - 
> it looks a little bit strange with a multipart/alternative 
> nested inside a multipart/related - I think nail should still 
> be able to recognize and display the contents.

mailx can principally handle such messages. However, this
particular message is broken; in its outermost header, it
specifies "----=_NextPart_000_B592D_01C77697.B60E93BA" as
boundary, but it does not use it in the following content.
Instead, it uses the boundary for the inner parts for the
outer parts as well. After replacing the inner part boundary
"----=_NextPart_000_B5931_01C77697.B613586E" by the outer
part boundary where appropriate (i.e. in lines 33, 276, 356,
and 405), the message is displayed as one would expect.

Perhaps mailx should resort to just dump the content as
text if the boundary is never used in the message; this
at least seems to be what mutt does in this situation.

> This is with nail 11.4. I wanted to check with the current 12.2 
> but unfortunately it did not compile with the following message:
> sendout.o: In function `start_mta':
> sendout.c:(.text+0x144d): undefined reference to `smtp_auth_var'

This happens if one compiles without socket support. It is
(Continue reading)

Gunnar Ritter | 4 Apr 2007 18:16
Picon
Favicon

Re: mime part not displayed

[added the mailing list to the recipients again]

Thomas.Wolff@... wrote:

> It should also check the mime type which can be recognized 
> clearly on each individual mime part, independently of its 
> proper arrangement within the multipart mail.
> So one of the parts in this mail should be dumped as text/html.

This is impossible with such a message. If the boundary is
defective, mailx does not know what lines constitute a part
at all (despite the fact that a human can easily _guess_
that). Thus, it interprets all lines as being positioned
before the first part (which never begins), and discards
them accordingly.

> Hmm, I just typed "make" without caring about "socket or not socket".
> I would not really know how to make this choice or even whether 
> to care at all by looking at README and INSTALL.

Then "makeconfig" did not properly detect socket support
in your system libraries. Could you perhaps have a look
at "config.log" and determine why?

Thank you

	Gunnar

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
(Continue reading)

Thomas Wolff | 4 Apr 2007 18:52

Re: mime part not displayed

> > Hmm, I just typed "make" without caring about "socket or not socket".
> > I would not really know how to make this choice or even whether 
> > to care at all by looking at README and INSTALL.

> Then "makeconfig" did not properly detect socket support
> in your system libraries. Could you perhaps have a look
> at "config.log" and determine why?

I found the problem: a "cp" command missing "-f" in makeconfig 
(I have scripts rm, cp, mv in my path which substitute -i by 
default which is safer in some cases than just having aliases 
or shell functions for this purpose).

Compiled fine now.

Thomas

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
Gunnar Ritter | 15 Apr 2007 13:27
Picon
Favicon

Re: mime part not displayed

Gunnar Ritter <gunnarr@...> wrote:

> This is impossible with such a message. If the boundary is
> defective, mailx does not know what lines constitute a part
> at all (despite the fact that a human can easily _guess_
> that). Thus, it interprets all lines as being positioned
> before the first part (which never begins), and discards
> them accordingly.

The CVS version now prints

[Missing multipart boundary - use "show" to display the raw message]

in this situation so that there is at least a notification
about the defective part.

	Gunnar

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
Gunnar Ritter | 15 Apr 2007 13:34
Picon
Favicon

Re: mime part not displayed

Thomas Wolff <towo@...> wrote:

> I found the problem: a "cp" command missing "-f" in makeconfig 
> (I have scripts rm, cp, mv in my path which substitute -i by 
> default which is safer in some cases than just having aliases 
> or shell functions for this purpose).

If you replace standard system commands by incompatible scripts,
I think resulting problems are within your own responsibility.
While I principally agree that using such scripts is the best
way to modify behavior, one must nevertheless ensure that they
do not interfere with non-interactive usage.

"cp -f" is a relatively new option, and may not be present on
all platforms mailx compiles on, so I am reluctant to add it.

	Gunnar

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

Gmane