aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-11-11 06:50:35 +0000
committerZac Medico <zmedico@gentoo.org>2009-11-11 06:50:35 +0000
commit3499c62516bd0e2c5b319effcfd00f6953308750 (patch)
tree963430918f6d30014e70dd876e8ba1cfaa647960 /pym/portage/mail.py
parentPreserve previous usage of MIMEText constructor under python2, since it's (diff)
downloadportage-3499c62516bd0e2c5b319effcfd00f6953308750.tar.gz
portage-3499c62516bd0e2c5b319effcfd00f6953308750.tar.bz2
portage-3499c62516bd0e2c5b319effcfd00f6953308750.zip
Convert MIMEText body to string before sending.
svn path=/main/trunk/; revision=14808
Diffstat (limited to 'pym/portage/mail.py')
-rw-r--r--pym/portage/mail.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pym/portage/mail.py b/pym/portage/mail.py
index 96bb38e83..42ed43b83 100644
--- a/pym/portage/mail.py
+++ b/pym/portage/mail.py
@@ -133,7 +133,7 @@ def send_mail(mysettings, message):
myconn = smtplib.SMTP(mymailhost, mymailport)
if mymailuser != "" and mymailpasswd != "":
myconn.login(mymailuser, mymailpasswd)
- myconn.sendmail(myfrom, myrecipient, message)
+ myconn.sendmail(myfrom, myrecipient, message.as_string())
myconn.quit()
except smtplib.SMTPException as e:
raise portage.exception.PortageException(_("!!! An error occured while trying to send logmail:\n")+str(e))