#4768: store base64 encoded email body parts as text, not binary.

Patch and tests by Forest Bond.
This commit is contained in:
R. David Murray 2010-06-04 16:11:08 +00:00
parent deda8cb835
commit 7da8f06df0
4 changed files with 10 additions and 4 deletions

View file

@ -29,7 +29,7 @@ def encode_base64(msg):
Also, add an appropriate Content-Transfer-Encoding header.
"""
orig = msg.get_payload()
encdata = _bencode(orig)
encdata = str(_bencode(orig), 'ascii')
msg.set_payload(encdata)
msg['Content-Transfer-Encoding'] = 'base64'