[haiku-3rdparty-dev] Re: BEmailMessage

  • From: Andrew Wood <andrew@xxxxxxxxxxxxxxxxxxxxx>
  • To: haiku-3rdparty-dev@xxxxxxxxxxxxx
  • Date: Wed, 12 Nov 2014 21:41:24 +0000

Apologies for the delay in following this up but Ive been doing some investigating and discovered it doesnt actually look like its anything to do with UTF8 - its folded Content-Type headers it corrupts.


If I 'unfold' the content-type header into 1 line before passing it to BEMailMessage then it works fine.

At the moment though I cant see in the Mail Kit why this is a problem, but presuably somewhere its making an assumption that Content-Type will only ever be a 1 liner and many mail clients fold it over 2 lines.


On 11/10/2014 23:26, Andrew Wood wrote:
As its a mailing list server its basically copied over pretty much verbatim from the senders incoming mail with just some small header adjustments dumped as plain text into a file and the file passed to the BEmailMessage constructor.


On 08/10/2014 08:36, Axel Dörfler wrote:
Am 04.10.2014 23:44, schrieb Andrew Wood:
After doing some tests the problem appears to be a modification to the
Content-Type header

The incoming email and the one passed to BEmailMessage is in the form:
Content-Type: multipart/mixed;
     boundary="_AA8B9F75-F456-45D0-96E8-99EF801DCBD4_"

but having passed through BEmailMessage and sent it ends up as:

Content-Type:
  multipart/mixed;
=?iso-8859-15?q?boundary=3D?="_AA8B9F75-F456-45D0-96E8-99EF801DCBD4_

Why does it do this and is there a way to prevent it?

How do you fill the message? The default content type in the mail kit is iso-8859-15. Unless you specify a different one, this is the one being used.

Bye,
   Axel.





Other related posts: