[Python-checkins] cpython (3.1): #11590: fix quoprimime decode handling of empty strings and line endings. (original) (raw)

r.david.murray python-checkins at python.org
Wed Mar 23 20:37:44 CET 2011


http://hg.python.org/cpython/rev/45cc298d40eb changeset: 68875:45cc298d40eb branch: 3.1 parent: 68870:3dbea3fa73fb user: R David Murray <rdmurray at bitdance.com> date: Wed Mar 23 15:25:55 2011 -0400 summary: #11590: fix quoprimime decode handling of empty strings and line endings.

files: Lib/email/quoprimime.py | 6 +++--- Lib/email/test/test_email.py | 15 +++++++++++++++ 2 files changed, 18 insertions(+), 3 deletions(-)

diff --git a/Lib/email/quoprimime.py b/Lib/email/quoprimime.py --- a/Lib/email/quoprimime.py +++ b/Lib/email/quoprimime.py @@ -135,9 +135,9 @@ charset names the character set to use in the RFC 2046 header. It defaults to iso-8859-1. """

diff --git a/Lib/email/test/test_email.py b/Lib/email/test/test_email.py --- a/Lib/email/test/test_email.py +++ b/Lib/email/test/test_email.py @@ -2890,6 +2890,9 @@ encoded_header = quoprimime.header_encode(header, charset) self.assertEqual(encoded_header, expected_encoded_header)

@@ -2946,6 +2949,15 @@ def test_decode_one_line_lf(self): self._test_decode('hello\n', 'hello\n')

@@ -2955,6 +2967,9 @@ def test_decode_two_lines(self): self._test_decode('hello\r\nworld\r\n', 'hello\nworld\n')

-- Repository URL: http://hg.python.org/cpython



More information about the Python-checkins mailing list