diff options
| author | Victor Stinner <victor.stinner@haypocalc.com> | 2011-09-22 23:15:32 (GMT) |
|---|---|---|
| committer | Victor Stinner <victor.stinner@haypocalc.com> | 2011-09-22 23:15:32 (GMT) |
| commit | 51b719814e0c32fd0eea570d3769d323bea97cab (patch) | |
| tree | c6b7ca9161cca8f06b42217244cb59a5b51370db /Lib/xmlrpclib.py | |
| parent | 2156594d8c9ce7ca8b3552d4a3e1043bc602d717 (diff) | |
| download | cpython-51b719814e0c32fd0eea570d3769d323bea97cab.zip cpython-51b719814e0c32fd0eea570d3769d323bea97cab.tar.gz cpython-51b719814e0c32fd0eea570d3769d323bea97cab.tar.bz2 | |
Issue #12931: xmlrpclib now encodes Unicode URI to ISO-8859-1, instead of
failing with a UnicodeDecodeError.
Diffstat (limited to 'Lib/xmlrpclib.py')
| -rw-r--r-- | Lib/xmlrpclib.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/xmlrpclib.py b/Lib/xmlrpclib.py index 3cba39f..653c424 100644 --- a/Lib/xmlrpclib.py +++ b/Lib/xmlrpclib.py @@ -1539,6 +1539,9 @@ class ServerProxy: allow_none=0, use_datetime=0): # establish a "logical" server connection + if isinstance(uri, unicode): + uri = uri.encode('ISO-8859-1') + # get the url import urllib type, uri = urllib.splittype(uri) |
