diff options
| author | Barry Warsaw | 2007-12-29 19:53:23 -0500 |
|---|---|---|
| committer | Barry Warsaw | 2007-12-29 19:53:23 -0500 |
| commit | 86f00a6cec71753952d1290bdadd836fdba5fdc1 (patch) | |
| tree | 94bd4167060de21e706fc6dec1848092febaa57a /Mailman/Handlers | |
| parent | 68cce110887cc9fc46fd4c7798f3b8d893f1038f (diff) | |
| download | mailman-86f00a6cec71753952d1290bdadd836fdba5fdc1.tar.gz mailman-86f00a6cec71753952d1290bdadd836fdba5fdc1.tar.zst mailman-86f00a6cec71753952d1290bdadd836fdba5fdc1.zip | |
Port the maximum message size check to a rule. Add doctest.
Rename the implicit.txt doctest.
specialized_message_from_string(): Mimic the way the text->message parser will
include the size of the original text as an attribute on the message object.
The maximum message size rule will use this information.
Diffstat (limited to 'Mailman/Handlers')
| -rw-r--r-- | Mailman/Handlers/Hold.py | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/Mailman/Handlers/Hold.py b/Mailman/Handlers/Hold.py index 12bab8a8b..81dab3189 100644 --- a/Mailman/Handlers/Hold.py +++ b/Mailman/Handlers/Hold.py @@ -165,22 +165,6 @@ def process(mlist, msg, msgdata): # message because the info would also go to the sender hold_for_approval(mlist, msg, msgdata, SuspiciousHeaders) # no return - # - # Is the message too big? - if mlist.max_message_size > 0: - bodylen = 0 - for line in email.Iterators.body_line_iterator(msg): - bodylen += len(line) - for part in msg.walk(): - if part.preamble: - bodylen += len(part.preamble) - if part.epilogue: - bodylen += len(part.epilogue) - if bodylen/1024.0 > mlist.max_message_size: - hold_for_approval(mlist, msg, msgdata, - MessageTooBig(bodylen, mlist.max_message_size)) - # no return - # # Are we gatewaying to a moderated newsgroup and is this list the # moderator's address for the group? if mlist.news_moderation == 2: |
