Mercurial > public > mercurial-scm > hg
diff mercurial/revlog.py @ 4258:b11a2fb59cf5
revlog: simplify revlog version handling
- pass the default version as an attribute on the opener
- eliminate config option mess
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Thu, 22 Mar 2007 19:52:38 -0500 |
parents | 1b5c38e9d7aa |
children | 0ce23256e454 |
line wrap: on
line diff
--- a/mercurial/revlog.py Thu Mar 22 19:12:03 2007 -0500 +++ b/mercurial/revlog.py Thu Mar 22 19:52:38 2007 -0500 @@ -311,7 +311,7 @@ remove data, and can use some simple techniques to avoid the need for locking while reading. """ - def __init__(self, opener, indexfile, defversion=REVLOG_DEFAULT_VERSION): + def __init__(self, opener, indexfile): """ create a revlog object @@ -325,7 +325,9 @@ self.indexstat = None self.cache = None self.chunkcache = None - self.defversion = defversion + self.defversion=REVLOG_DEFAULT_VERSION + if hasattr(opener, "defversion"): + self.defversion = opener.defversion self.load() def load(self):