changeset 17200:19f5dec2d61f

obsolete: os.SEEK_END first appeared in Python 2.5 fixes 48c232873a54 failing for Python 2.4
author Adrian Buehlmann <adrian@cadifra.com>
date Tue, 17 Jul 2012 00:55:22 +0200
parents c6e38fdff23c
children afd75476939e
files mercurial/obsolete.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/obsolete.py	Sun Jul 15 12:43:10 2012 -0400
+++ b/mercurial/obsolete.py	Tue Jul 17 00:55:22 2012 +0200
@@ -51,7 +51,7 @@
   additional encoding. Keys cannot contain '\0' or ':' and values
   cannot contain '\0'.
 """
-import os, struct
+import struct
 from mercurial import util, base85
 from i18n import _
 
@@ -200,7 +200,7 @@
                 # defined. So we must seek to the end before calling tell(),
                 # or we may get a zero offset for non-zero sized files on
                 # some platforms (issue3543).
-                f.seek(0, os.SEEK_END)
+                f.seek(0, 2) # os.SEEK_END
                 offset = f.tell()
                 transaction.add('obsstore', offset)
                 if offset == 0: