[Python-Dev] Found a bug!

Barry Warsaw barry at python.org
Tue Aug 19 04:13:40 EDT 2003

Well, I was debugging a Mailman user's problem when I hit what I think
is a bug in mimelib/email pkg.  I don't yet know if this is related to
the MM bug because I can't get as far through the code, but you don't
care about that. :)

I believe mimelib is not handling RFC 2231 headers such as the following

Content-Disposition: inline;
 filename*2="is it not.pdf"

Try creating a message with a header like this and doing a
msg.get_filename() on it -- you'll get a TypeError.  The bug is that
get_filename() isn't prepared for a missing language parameter.

The fix is probably simple, and I'll try to resist doing too much
refactoring <wink>.  I'll check in a test case and a patch and backport
it to the Python 2.3.1 and 2.2.4 branches.


More information about the Python-Dev mailing list