summaryrefslogtreecommitdiffstats
path: root/Lib/codecs.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/codecs.py')
-rw-r--r--Lib/codecs.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/Lib/codecs.py b/Lib/codecs.py
index 884be0b..21c45a7 100644
--- a/Lib/codecs.py
+++ b/Lib/codecs.py
@@ -847,6 +847,12 @@ class StreamRecoder:
self.reader.reset()
self.writer.reset()
+ def seek(self, offset, whence=0):
+ # Seeks must be propagated to both the readers and writers
+ # as they might need to reset their internal buffers.
+ self.reader.seek(offset, whence)
+ self.writer.seek(offset, whence)
+
def __getattr__(self, name,
getattr=getattr):