From ced2e7b72d982e2c91dce1aaf611a7b9ed1be301 Mon Sep 17 00:00:00 2001 From: Valentin Lorentz Date: Sat, 4 Aug 2012 21:24:17 +0200 Subject: [PATCH] Implement seed, tell, and flush to AtomicFile. --- src/utils/file.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/utils/file.py b/src/utils/file.py index 800e4acab..1a94ecd8f 100644 --- a/src/utils/file.py +++ b/src/utils/file.py @@ -174,6 +174,15 @@ class AtomicFile(object): os.remove(self.tempFilename) self.rolledback = True + def seek(self, offset): + return self._fd.seek(offset) + + def tell(self): + return self._fd.tell() + + def flush(self): + return self._fd.flush() + def close(self): if not self.rolledback: self._fd.close()