Fix utf7 decode error not caught
Signed-off-by: Stéphane Albert <sheeprine@oh.its.fake.nullplace.com> Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
parent
2d885fda4c
commit
75f16106da
@ -368,5 +368,5 @@ def decode_mailbox_name(name):
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
return ret.decode('utf-7').encode('utf-8')
|
return ret.decode('utf-7').encode('utf-8')
|
||||||
except UnicodeEncodeError:
|
except (UnicodeDecodeError, UnicodeEncodeError):
|
||||||
return name
|
return name
|
||||||
|
Loading…
Reference in New Issue
Block a user