[Python-checkins] python/dist/src/Lib codecs.py,1.47,1.48
doerwalter@users.sourceforge.net
doerwalter at users.sourceforge.net
Thu Sep 1 13:57:04 CEST 2005
Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27925/Lib
Modified Files:
codecs.py
Log Message:
SF bug #1235646: codecs.StreamRecoder.next() now reencodes the data it reads
from the input stream, so that the output is a byte string in the correct
encoding instead of a unicode string.
Index: codecs.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/codecs.py,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -d -r1.47 -r1.48
--- codecs.py 24 Aug 2005 07:38:12 -0000 1.47
+++ codecs.py 1 Sep 2005 11:56:53 -0000 1.48
@@ -556,7 +556,9 @@
def next(self):
""" Return the next decoded line from the input stream."""
- return self.reader.next()
+ data = self.reader.next()
+ data, bytesencoded = self.encode(data, self.errors)
+ return data
def __iter__(self):
return self
More information about the Python-checkins
mailing list