------------------------------------------------------------
revno: 1286
committer: Mark Sapiro <[email protected]>
branch nick: 2.1
timestamp: Thu 2011-04-07 19:12:56 -0700
message:
Fix for bug #701558 went to far. Don't recast message/rfc822 parts.
We want to keep the headers.
modified:
Mailman/Handlers/MimeDel.py
--
lp:mailman/2.1
https://code.launchpad.net/~mailman-coders/mailman/2.1
Your team Mailman Checkins is subscribed to branch lp:mailman/2.1.
To unsubscribe from this branch go to
https://code.launchpad.net/~mailman-coders/mailman/2.1/+edit-subscription
=== modified file 'Mailman/Handlers/MimeDel.py'
--- Mailman/Handlers/MimeDel.py 2011-01-14 01:00:40 +0000
+++ Mailman/Handlers/MimeDel.py 2011-04-08 02:12:56 +0000
@@ -201,9 +201,11 @@
def recast_multipart(msg):
# If we're left with a multipart message with only one sub-part, recast
- # the message to just the sub-part.
+ # the message to just the sub-part, but not if the part is message/rfc822
+ # because we don't want to lose the headers.
if msg.is_multipart():
- if len(msg.get_payload()) == 1:
+ if (len(msg.get_payload()) == 1 and
+ msg.get_content_type() <> 'message/rfc822'):
reset_payload(msg, msg.get_payload(0))
# now that we've recast this part, check the subordinate parts
recast_multipart(msg)
_______________________________________________
Mailman-checkins mailing list
[email protected]
Unsubscribe:
http://mail.python.org/mailman/options/mailman-checkins/archive%40jab.org