On 27/05/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hi,
> can anyone comment on whether the Byte Order Mark is necessary for
> Mime Messages?
it not break correct unicode reader and some email clients ignoring
content type and detecting unicode by bom. so, synapse trying o be most
compatible.
I see, but this breaks signed messages; the message is signed with the
BOM, then the recepient mail client removes the BOM and signature
verification fails.
Either way I have modified the code, adding a property indicating
whether to include the BOM.
If you are able & willing, would you mind implementing these couple of
changes to the Synapse source:
Thanks.
----
unit MimeMess:
interface section
(1) method TMessHeader.Clear : make virtual.
(2) method TMimeMess.Clear: make virtual.
unit MimePart:
interface section
(1) Add public property: property AddBOM : Boolean read FAddBom write FAddBom;
(2) Add private method: function AdjustBOM(const BOM : string) : string;
implementation section
(1) In TMimePart.Create: FAddBom := True;
(2) function TMimePart.AdjustBOM(const BOM: string): string;
begin
Result := BOM;
if not FAddBom then Result := '';
end;
(3) In TMimePart.EncodePart,line 864, Add AdjustBOM() around GetBom()
if FConvertCharset and (FPrimaryCode = MP_TEXT) and
(FEncodingCode <> ME_7BIT) then
s := AdjustBOM(GetBOM(FCharSetCode)) +
CharsetConversion(s, FTargetCharset, FCharsetCode);
-------------------------------------------------------
All the advantages of Linux Managed Hosting--Without the Cost and Risk!
Fully trained technicians. The highest number of Red Hat certifications in
the hosting industry. Fanatical Support. Click to learn more
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642
_______________________________________________
synalist-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/synalist-public