Skip to content

Commit 6475b05

Browse files
committed
Fix issue2550565.
1 parent d8bbe46 commit 6475b05

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

roundup/mailer.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
"""Sending Roundup-specific mail over SMTP.
22
"""
33
__docformat__ = 'restructuredtext'
4-
# $Id: mailer.py,v 1.22 2008-07-21 01:44:58 richard Exp $
54

65
import time, quopri, os, socket, smtplib, re, sys, traceback, email
76

@@ -117,7 +116,7 @@ def standard_message(self, to, subject, content, author=None):
117116
message = self.get_standard_message(to, subject, author)
118117
message.set_payload(content)
119118
encode_quopri(message)
120-
self.smtp_send(to, str(message))
119+
self.smtp_send(to, message.as_string())
121120

122121
def bounce_message(self, bounced_message, to, error,
123122
subject='Failed issue tracker submission'):
@@ -163,7 +162,7 @@ def bounce_message(self, bounced_message, to, error,
163162

164163
# send
165164
try:
166-
self.smtp_send(to, str(message))
165+
self.smtp_send(to, message.as_string())
167166
except MessageSendError:
168167
# squash mail sending errors when bouncing mail
169168
# TODO this *could* be better, as we could notify admin of the

roundup/roundupdb.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1717
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1818
#
19-
# $Id: roundupdb.py,v 1.139 2008-08-07 06:31:16 richard Exp $
2019

2120
"""Extending hyperdb with types specific to issue-tracking.
2221
"""
@@ -499,9 +498,9 @@ def send_message(self, nodeid, msgid, note, sendto, from_address=None,
499498
encode_quopri(message)
500499

501500
if first:
502-
mailer.smtp_send(sendto + bcc_sendto, str(message))
501+
mailer.smtp_send(sendto + bcc_sendto, message.as_string())
503502
else:
504-
mailer.smtp_send(sendto, str(message))
503+
mailer.smtp_send(sendto, message.as_string())
505504
first = False
506505

507506
def email_signature(self, nodeid, msgid):

0 commit comments

Comments
 (0)