Re: BUG: filter_begin always gets a multipart MIME::Entity
Dianne Skoll <[email protected]> Wed, 12 Jul 2017 07:14:56 -0400
| Newsgroups | gmane.mail.mimedefang |
|---|---|
| Organization | Roaring Penguin Software Inc. |
| Message-ID | <[email protected]> |
On Wed, 12 Jul 2017 00:35:17 -0400 "Bill Cole" <[email protected]> wrote: > This is apparently > a manifestation of documented behavior in an undocumented > circumstance: mimedefang-filter (5) says an existing message that is > not already multipart/mixed will be wrapped in a multipart/mixed > container if you call action_add_part(). I don't. Anywhere. Ever. Actually, the documentation isn't quite right. MIMEDefang unconditionally wraps the message. Here's the code: $entity = $parser->parse(\*FILE); [...] # Make entity multipart my ($code); $code = $entity->make_multipart(); $WasMultiPart = ($code eq 'ALREADY'); There's an escape hatch: You can check the (undocumented, alas) global variable $WasMultiPart to determine if the original message was multipart. Regards, Dianne. _______________________________________________ NOTE: If there is a disclaimer or other legal boilerplate in the above message, it is NULL AND VOID. You may ignore it. Visit http://www.mimedefang.org and http://www.roaringpenguin.com MIMEDefang mailing list [email protected] http://lists.roaringpenguin.com/mailman/listinfo/mimedefang