Use os.SEEK_END instead of io.SEEK_END for Python 2.6 compatibility