mirror of
https://github.com/python/cpython.git
synced 2025-10-10 00:43:41 +00:00
#25328: add missing raise keyword in decode_data+SMTPUTF8 check.
This is a relatively benign bug, since having both be true was correctly rejected at in SMTPServer even before this patch. Patch by Xiang Zhang.
This commit is contained in:
parent
5ae56919ab
commit
1a815389cc
3 changed files with 11 additions and 2 deletions
|
@ -137,8 +137,8 @@ class SMTPChannel(asynchat.async_chat):
|
|||
self.enable_SMTPUTF8 = enable_SMTPUTF8
|
||||
if enable_SMTPUTF8:
|
||||
if decode_data:
|
||||
ValueError("decode_data and enable_SMTPUTF8 cannot be set to"
|
||||
" True at the same time")
|
||||
raise ValueError("decode_data and enable_SMTPUTF8 cannot"
|
||||
" be set to True at the same time")
|
||||
decode_data = False
|
||||
if decode_data is None:
|
||||
warn("The decode_data default of True will change to False in 3.6;"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue