summaryrefslogtreecommitdiffstats
path: root/Lib/codecs.py
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2010-05-22 02:16:27 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2010-05-22 02:16:27 (GMT)
commit3fed0870a6fec72665068e09200c674b574dabdb (patch)
tree8562dd597347a6a8336ba001f065d3ab3b712775 /Lib/codecs.py
parent7126dbc867e99e675ed29037c6b10681dbaa8dc9 (diff)
downloadcpython-3fed0870a6fec72665068e09200c674b574dabdb.zip
cpython-3fed0870a6fec72665068e09200c674b574dabdb.tar.gz
cpython-3fed0870a6fec72665068e09200c674b574dabdb.tar.bz2
Merged revisions 81459 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r81459 | victor.stinner | 2010-05-22 04:11:07 +0200 (sam., 22 mai 2010) | 3 lines Issue #6268: Fix seek() method of codecs.open(), don't read the BOM twice after seek(0) ........
Diffstat (limited to 'Lib/codecs.py')
-rw-r--r--Lib/codecs.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/codecs.py b/Lib/codecs.py
index f05c4f7..9490602 100644
--- a/Lib/codecs.py
+++ b/Lib/codecs.py
@@ -699,6 +699,10 @@ class StreamReaderWriter:
self.reader.reset()
self.writer.reset()
+ def seek(self, offset, whence=0):
+ self.reader.seek(offset, whence)
+ self.writer.seek(offset, whence)
+
def __getattr__(self, name,
getattr=getattr):