This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: email iter_attachments can mutate the payload
Type: behavior Stage: resolved
Components: email Versions: Python 3.6, Python 3.5
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: barry, r.david.murray
Priority: normal Keywords: patch

Created on 2016-09-07 01:57 by r.david.murray, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
iter_attachments_mutation.patch r.david.murray, 2016-09-07 01:57 review
Messages (3)
msg274700 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2016-09-07 01:57
In the right (wrong) circumstances the iter_attachments function may mutate the payload list.  The fix is simple (make a copy before operating on it).  Attached is a patch with test.
msg274763 - (view) Author: Barry A. Warsaw (barry) * (Python committer) Date: 2016-09-07 05:55
LGTM +1
msg274849 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2016-09-07 17:43
I forgot the # on the issue number in the commit.  The hashes are:

3.5 3bf2f6818719
3.6 69da5242aae3
History
Date User Action Args
2022-04-11 14:58:35adminsetgithub: 72175
2016-09-07 17:43:38r.david.murraysetstatus: open -> closed
resolution: fixed
messages: + msg274849

stage: commit review -> resolved
2016-09-07 05:55:58barrysetmessages: + msg274763
2016-09-07 01:57:46r.david.murraysetnosy: + barry
components: + email
2016-09-07 01:57:16r.david.murraycreate