Message272537
| Author |
martin.panter |
| Recipients |
Lukasa, barry, demian.brecht, icordasc, martin.panter, mgdelmonte, piotr.dobrogost, r.david.murray |
| Date |
2016年08月12日.12:37:52 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1471005474.46.0.702572911864.issue24363@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
In order to avoid messing too much with the intricacies of the existing email parsing, here is a patch for Python 3 that limits the behaviour changes to the HTTP module. It should fix the bad handling of broken header lines. As a side effect, it should also fix Issue 22233, since it bypasses the offending splitlines() call. I incorporated the test cases from my previous patches for Issue 26686 and Issue 22233.
I tried to maintain a minimal compatibility with the previous special behaviour for message/* and multipart/* message types, although I didn’t bother trying to emulate e.g. StartBoundaryNotFoundDefect (http.client.parse_headers() doesn’t pass any body to the email parser, so it won’t see any start boundaries.) |
|