[Python-checkins] python/dist/src/Lib xmlrpclib.py,1.36,1.36.2.1

fdrake at users.sourceforge.net fdrake at users.sourceforge.net
Fri Feb 11 19:00:26 CET 2005


Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv18573/Lib

Modified Files:
      Tag: release24-maint
	xmlrpclib.py 
Log Message:
fix decoding in _stringify to not depend on the default encoding
(closes SF bug #1115989)


Index: xmlrpclib.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/xmlrpclib.py,v
retrieving revision 1.36
retrieving revision 1.36.2.1
diff -u -d -r1.36 -r1.36.2.1
--- xmlrpclib.py	13 Oct 2004 06:48:37 -0000	1.36
+++ xmlrpclib.py	11 Feb 2005 17:59:58 -0000	1.36.2.1
@@ -168,7 +168,7 @@
     def _stringify(string):
         # convert to 7-bit ascii if possible
         try:
-            return str(string)
+            return string.encode("ascii")
         except UnicodeError:
             return string
 else:



More information about the Python-checkins mailing list