Author falon
Recipients barry, falon, r.david.murray
Date 2020-02-13.15:05:28
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1581606328.48.0.533988298686.issue39628@roundup.psfhosted.org>
In-reply-to
Content
Hello,

 if I write

```
msg = email.message_from_bytes(...)
for part in msg.walk():
  content_type = part.get_content_type()
  if not part.get_content_maintype() == 'multipart':
     filename = part.get_filename(None)
     attachment = part.get_payload(decode=True)
```

if the mime parts are more than one, then the memory increases at each iteration and will never be released.
History
Date User Action Args
2020-02-13 15:05:28falonsetrecipients: + falon, barry, r.david.murray
2020-02-13 15:05:28falonsetmessageid: <1581606328.48.0.533988298686.issue39628@roundup.psfhosted.org>
2020-02-13 15:05:28falonlinkissue39628 messages
2020-02-13 15:05:28faloncreate