[Python-checkins] cpython: Fixed a type error introduced in issue #28992.
serhiy.storchaka
python-checkins at python.org
Wed Dec 21 07:09:13 EST 2016
https://hg.python.org/cpython/rev/6ced540a92bc
changeset: 105771:6ced540a92bc
user: Serhiy Storchaka <storchaka at gmail.com>
date: Wed Dec 21 14:08:55 2016 +0200
summary:
Fixed a type error introduced in issue #28992.
files:
Lib/email/_encoded_words.py | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Lib/email/_encoded_words.py b/Lib/email/_encoded_words.py
--- a/Lib/email/_encoded_words.py
+++ b/Lib/email/_encoded_words.py
@@ -62,7 +62,7 @@
# regex based decoder.
_q_byte_subber = functools.partial(re.compile(br'=([a-fA-F0-9]{2})').sub,
- lambda m: bytes.fromhex(m.group(1)))
+ lambda m: bytes.fromhex(m.group(1).decode()))
def decode_q(encoded):
encoded = encoded.replace(b'_', b' ')
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list